/**
 * BizToolbox Core - Tools & Document Generator Styles
 */

:root {
	--bt-blue-50: #eff6ff;
	--bt-blue-100: #dbeafe;
	--bt-blue-200: #bfdbfe;
	--bt-blue-500: #3b82f6;
	--bt-blue-600: #2563eb;
	--bt-blue-700: #1d4ed8;
	--bt-navy-900: #0a0f1d;
	--bt-navy-800: #0f172a;
	--bt-navy-700: #1e293b;
	--bt-slate-50: #f8fafc;
	--bt-slate-100: #f1f5f9;
	--bt-slate-200: #e2e8f0;
	--bt-slate-300: #cbd5e1;
	--bt-slate-400: #94a3b8;
	--bt-slate-500: #64748b;
	--bt-slate-600: #475569;
	--bt-slate-700: #334155;
	--bt-slate-800: #1e293b;
	--bt-slate-900: #0f172a;
	--bt-green-600: #16a34a;
	--bt-green-50: #f0fdf4;
	--bt-red-600: #dc2626;
	--bt-red-50: #fef2f2;
	--bt-radius-sm: 8px;
	--bt-radius-md: 12px;
	--bt-radius-lg: 18px;
	--bt-radius-full: 9999px;
	--bt-shadow-sm: 0 1px 3px rgba(0,0,0,0.05), 0 1px 2px rgba(0,0,0,0.03);
	--bt-shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.04);
	--bt-shadow-lg: 0 12px 24px -4px rgba(15,23,42,0.08), 0 4px 8px -2px rgba(15,23,42,0.03);
}

/* ==========================================================================
   Base Tool Wrapper & Card
   ========================================================================== */
.bt-calculator-wrapper,
.bt-document-generator-wrapper {
	margin: 2rem 0;
	font-family: inherit;
	color: var(--bt-slate-900);
}

.bt-calc-card {
	background: #ffffff;
	border: 1px solid var(--bt-slate-200);
	border-radius: var(--bt-radius-lg);
	box-shadow: var(--bt-shadow-lg);
	overflow: hidden;
	padding: 1.5rem;
}

@media (min-width: 768px) {
	.bt-calc-card {
		padding: 2.25rem;
	}
}

/* Top bar */
.bt-calc-header-bar,
.bt-doc-top-bar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
	gap: 1rem;
	padding-bottom: 1.25rem;
	border-bottom: 1px solid var(--bt-slate-200);
	margin-bottom: 1.5rem;
}

.bt-calc-title,
.bt-doc-type-badge {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	flex-wrap: wrap;
}

.bt-live-calc-tag,
.bt-live-saved-indicator {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	font-size: 0.8125rem;
	font-weight: 500;
	color: var(--bt-slate-500);
}

.bt-dot-pulse {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background-color: var(--bt-green-600);
	box-shadow: 0 0 0 rgba(22, 163, 74, 0.4);
	animation: btPulse 2s infinite;
}

@keyframes btPulse {
	0% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.6); }
	70% { box-shadow: 0 0 0 8px rgba(22, 163, 74, 0); }
	100% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0); }
}

/* Badges */
.bt-badge {
	display: inline-flex;
	align-items: center;
	padding: 0.25rem 0.75rem;
	border-radius: var(--bt-radius-full);
	font-size: 0.75rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.bt-badge-blue {
	background-color: var(--bt-blue-50);
	color: var(--bt-blue-700);
	border: 1px solid var(--bt-blue-200);
}

.bt-badge-navy {
	background-color: var(--bt-navy-900);
	color: #ffffff;
}

.bt-badge-sm {
	padding: 0.15rem 0.5rem;
	font-size: 0.6875rem;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.bt-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	padding: 0.625rem 1.25rem;
	font-size: 0.9375rem;
	font-weight: 600;
	border-radius: var(--bt-radius-full);
	cursor: pointer;
	border: 1px solid transparent;
	transition: all 0.2s ease-in-out;
	text-decoration: none;
	line-height: 1.25;
}

.bt-btn-primary {
	background-color: var(--bt-blue-600);
	color: #ffffff;
	box-shadow: 0 2px 4px rgba(37, 99, 235, 0.25);
}

.bt-btn-primary:hover,
.bt-btn-primary:focus {
	background-color: var(--bt-blue-700);
	box-shadow: 0 4px 10px rgba(37, 99, 235, 0.35);
	transform: translateY(-1px);
}

.bt-btn-secondary {
	background-color: var(--bt-slate-100);
	color: var(--bt-slate-800);
	border-color: var(--bt-slate-200);
}

.bt-btn-secondary:hover {
	background-color: var(--bt-slate-200);
	color: var(--bt-slate-900);
}

.bt-btn-outline {
	background-color: transparent;
	color: var(--bt-blue-600);
	border-color: var(--bt-blue-600);
}

.bt-btn-outline:hover {
	background-color: var(--bt-blue-50);
}

.bt-btn-subtle {
	background: transparent;
	border: 1px solid var(--bt-slate-200);
	color: var(--bt-slate-600);
	padding: 0.5rem;
	border-radius: var(--bt-radius-md);
}

.bt-btn-subtle:hover {
	background: var(--bt-slate-100);
	color: var(--bt-slate-900);
}

.bt-btn-sm {
	padding: 0.375rem 0.875rem;
	font-size: 0.8125rem;
}

.bt-btn-icon {
	background: transparent;
	border: 1px solid var(--bt-slate-200);
	color: var(--bt-slate-600);
	border-radius: var(--bt-radius-sm);
	padding: 0.375rem;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: all 0.2s;
}

.bt-btn-icon:hover {
	background: var(--bt-slate-100);
	color: var(--bt-slate-900);
}

/* ==========================================================================
   Form Controls & Inputs
   ========================================================================== */
.bt-form-group {
	margin-bottom: 1.25rem;
}

.bt-label {
	display: block;
	font-size: 0.875rem;
	font-weight: 600;
	color: var(--bt-slate-700);
	margin-bottom: 0.375rem;
}

.bt-input-wrapper {
	position: relative;
	display: flex;
	align-items: stretch;
	width: 100%;
	background-color: #ffffff;
	border: 1.5px solid var(--bt-slate-200);
	border-radius: var(--bt-radius-md);
	transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
	overflow: hidden;
}

.bt-input-wrapper:focus-within {
	border-color: var(--bt-blue-600);
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.bt-input,
.bt-form-select {
	width: 100%;
	padding: 0.625rem 0.875rem;
	font-size: 0.9375rem;
	color: var(--bt-slate-900);
	background-color: #ffffff;
	border: 1.5px solid var(--bt-slate-200);
	border-radius: var(--bt-radius-md);
	transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.bt-input-wrapper .bt-input,
.bt-input-wrapper .bt-form-select {
	flex: 1 1 auto;
	min-width: 0;
	width: 100%;
	border: none !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	background: transparent !important;
	padding: 0.625rem 0.875rem !important;
	color: var(--bt-slate-900);
	font-size: 0.9375rem;
}

.bt-input-wrapper .bt-input:focus,
.bt-input-wrapper .bt-form-select:focus {
	outline: none !important;
	border: none !important;
	box-shadow: none !important;
}

.bt-input-prefix,
.bt-input-suffix {
	position: static;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0 0.875rem;
	font-weight: 600;
	font-size: 0.875rem;
	color: var(--bt-slate-600);
	background-color: var(--bt-slate-100);
	user-select: none;
	white-space: nowrap;
	pointer-events: none;
	flex-shrink: 0;
}

.bt-input-prefix {
	border-right: 1.5px solid var(--bt-slate-200);
}

.bt-input-suffix {
	border-left: 1.5px solid var(--bt-slate-200);
}

.bt-input:focus,
.bt-form-select:focus {
	outline: none;
	border-color: var(--bt-blue-600);
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.bt-radio-group {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	margin-top: 0.25rem;
}

@media (min-width: 640px) {
	.bt-radio-group {
		flex-direction: row;
		gap: 1rem;
	}
}

.bt-radio-label {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	font-size: 0.875rem;
	cursor: pointer;
	color: var(--bt-slate-700);
}

.bt-2col-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 1rem;
}

/* ==========================================================================
   Calculator Grid & Results Box
   ========================================================================== */
.bt-calc-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2rem;
}

@media (min-width: 900px) {
	.bt-calc-grid {
		grid-template-columns: 1fr 1fr;
	}
}

.bt-calc-form-actions {
	display: flex;
	gap: 0.75rem;
	margin-top: 1.5rem;
	flex-wrap: wrap;
}

.bt-results-card {
	background: var(--bt-slate-50);
	border: 1.5px solid var(--bt-slate-200);
	border-radius: var(--bt-radius-md);
	padding: 1.5rem;
	height: 100%;
	display: flex;
	flex-direction: column;
}

.bt-results-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding-bottom: 0.75rem;
	border-bottom: 1px solid var(--bt-slate-200);
	margin-bottom: 1.25rem;
}

.bt-results-heading {
	font-size: 1rem;
	font-weight: 700;
	color: var(--bt-slate-800);
	margin: 0;
}

.bt-results-empty-state {
	text-align: center;
	padding: 3rem 1rem;
	color: var(--bt-slate-500);
}

.bt-empty-icon {
	margin-bottom: 0.75rem;
}

.bt-results-list {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.bt-result-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 0.75rem 1rem;
	background: #ffffff;
	border-radius: var(--bt-radius-sm);
	border: 1px solid var(--bt-slate-200);
}

.bt-result-row.bt-highlight-row {
	background: var(--bt-blue-50);
	border-color: var(--bt-blue-200);
}

.bt-result-label {
	font-size: 0.875rem;
	font-weight: 600;
	color: var(--bt-slate-600);
}

.bt-result-value {
	font-size: 1.125rem;
	font-weight: 800;
	color: var(--bt-slate-900);
}

.bt-result-row.bt-highlight-row .bt-result-value {
	color: var(--bt-blue-700);
	font-size: 1.35rem;
}

/* ==========================================================================
   Document Generator (Invoice / Receipt / Quote / Estimate) Sheet
   ========================================================================== */
.bt-doc-paper-container {
	background: var(--bt-slate-100);
	padding: 1rem;
	border-radius: var(--bt-radius-lg);
	border: 1px solid var(--bt-slate-200);
}

@media (min-width: 768px) {
	.bt-doc-paper-container {
		padding: 2rem;
	}
}

.bt-doc-sheet {
	background: #ffffff;
	max-width: 850px;
	margin: 0 auto;
	padding: 2rem;
	border-radius: var(--bt-radius-md);
	box-shadow: var(--bt-shadow-md);
	box-sizing: border-box;
}

@media (min-width: 768px) {
	.bt-doc-sheet {
		padding: 3rem;
	}
}

.bt-sheet-header {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

@media (min-width: 640px) {
	.bt-sheet-header {
		flex-direction: row;
		justify-content: space-between;
	}
}

.bt-sheet-from {
	flex: 1;
}

.bt-sheet-input {
	border: 1px dashed transparent;
	border-radius: 4px;
	padding: 0.25rem 0.5rem;
	font-family: inherit;
	color: inherit;
	transition: border-color 0.2s;
	width: 100%;
	box-sizing: border-box;
}

.bt-sheet-input:hover,
.bt-sheet-input:focus,
.bt-sheet-textarea:hover,
.bt-sheet-textarea:focus {
	border-color: var(--bt-blue-500);
	background-color: var(--bt-blue-50);
	outline: none;
}

.bt-sheet-title-input {
	font-size: 1.25rem;
	font-weight: 800;
	color: var(--bt-slate-900);
	margin-bottom: 0.25rem;
}

.bt-sheet-textarea {
	border: 1px dashed transparent;
	border-radius: 4px;
	padding: 0.25rem 0.5rem;
	font-family: inherit;
	font-size: 0.875rem;
	color: var(--bt-slate-600);
	width: 100%;
	box-sizing: border-box;
	resize: vertical;
	line-height: 1.4;
}

.bt-sheet-meta {
	text-align: left;
}

@media (min-width: 640px) {
	.bt-sheet-meta {
		text-align: right;
		min-width: 240px;
	}
}

.bt-sheet-type-heading {
	font-size: 1.75rem;
	font-weight: 900;
	color: var(--bt-navy-900);
	margin: 0 0 0.75rem 0;
	letter-spacing: -0.02em;
}

.bt-meta-row {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin-bottom: 0.35rem;
	font-size: 0.875rem;
}

@media (min-width: 640px) {
	.bt-meta-row {
		justify-content: flex-end;
	}
}

.bt-meta-row label {
	font-weight: 600;
	color: var(--bt-slate-600);
}

.bt-sheet-meta-input {
	border: 1px dashed transparent;
	padding: 0.15rem 0.35rem;
	font-weight: 600;
	font-size: 0.875rem;
	color: var(--bt-slate-900);
	border-radius: 4px;
	width: 130px;
}

.bt-sheet-meta-input:hover,
.bt-sheet-meta-input:focus {
	border-color: var(--bt-blue-500);
	background: var(--bt-blue-50);
	outline: none;
}

.bt-sheet-divider {
	border: 0;
	border-top: 1px solid var(--bt-slate-200);
	margin: 1.5rem 0;
}

.bt-sheet-section-tag {
	display: block;
	font-size: 0.6875rem;
	font-weight: 700;
	color: var(--bt-slate-400);
	letter-spacing: 0.08em;
	margin-bottom: 0.25rem;
}

.bt-sheet-client-name {
	font-size: 1.05rem;
	font-weight: 700;
	color: var(--bt-slate-800);
}

/* Sheet Table */
.bt-sheet-items-section {
	margin: 1.5rem 0;
	overflow-x: auto;
}

.bt-sheet-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.875rem;
}

.bt-sheet-table th {
	background: var(--bt-slate-100);
	padding: 0.75rem;
	text-align: left;
	font-weight: 700;
	color: var(--bt-slate-700);
	border-bottom: 2px solid var(--bt-slate-200);
}

.bt-sheet-table td {
	padding: 0.625rem 0.75rem;
	border-bottom: 1px solid var(--bt-slate-200);
	vertical-align: middle;
}

.bt-sheet-table .col-desc { width: 50%; }
.bt-sheet-table .col-qty { width: 12%; text-align: center; }
.bt-sheet-table .col-rate { width: 18%; text-align: right; }
.bt-sheet-table .col-total { width: 15%; text-align: right; font-weight: 700; }
.bt-sheet-table .col-actions { width: 5%; text-align: center; }

.bt-sheet-item-desc {
	width: 100%;
	border: 1px dashed transparent;
	padding: 0.25rem 0.5rem;
	font-family: inherit;
	border-radius: 4px;
}

.bt-sheet-item-qty,
.bt-sheet-item-rate {
	width: 100%;
	border: 1px dashed transparent;
	padding: 0.25rem 0.35rem;
	text-align: right;
	border-radius: 4px;
	-moz-appearance: textfield;
	appearance: textfield;
}

.bt-sheet-item-qty::-webkit-outer-spin-button,
.bt-sheet-item-qty::-webkit-inner-spin-button,
.bt-sheet-item-rate::-webkit-outer-spin-button,
.bt-sheet-item-rate::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
	display: none;
}

.bt-sheet-item-desc:hover,
.bt-sheet-item-desc:focus,
.bt-sheet-item-qty:hover,
.bt-sheet-item-qty:focus,
.bt-sheet-item-rate:hover,
.bt-sheet-item-rate:focus {
	border-color: var(--bt-blue-500);
	background: var(--bt-blue-50);
	outline: none;
}

.bt-row-del-btn {
	background: transparent;
	border: none;
	color: var(--bt-slate-400);
	cursor: pointer;
	padding: 0.25rem;
	border-radius: 4px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

.bt-row-del-btn:hover {
	color: var(--bt-red-600);
	background: var(--bt-red-50);
}

.bt-sheet-table-actions {
	margin-top: 0.75rem;
}

/* Totals Section */
.bt-sheet-summary-section {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
	margin-top: 1.5rem;
}

@media (min-width: 640px) {
	.bt-sheet-summary-section {
		flex-direction: row;
		justify-content: space-between;
	}
}

.bt-sheet-notes-col {
	flex: 1;
}

.bt-sheet-label {
	display: block;
	font-size: 0.75rem;
	font-weight: 700;
	color: var(--bt-slate-600);
	margin-bottom: 0.25rem;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.bt-sheet-totals-col {
	min-width: 260px;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.bt-totals-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 0.875rem;
	padding: 0.25rem 0;
}

.bt-total-label {
	color: var(--bt-slate-600);
	font-weight: 500;
}

.bt-total-val {
	font-weight: 700;
	color: var(--bt-slate-900);
}

.bt-inline-calc-box {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.bt-sheet-mini-input {
	width: 55px;
	border: 1.5px solid var(--bt-slate-200);
	border-radius: 4px;
	padding: 0.15rem 0.35rem;
	text-align: right;
	font-size: 0.8125rem;
	-moz-appearance: textfield;
	appearance: textfield;
}

.bt-sheet-mini-input::-webkit-outer-spin-button,
.bt-sheet-mini-input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
	display: none;
}

.bt-totals-row.bt-grand-total-row {
	border-top: 2px solid var(--bt-slate-900);
	padding-top: 0.75rem;
	margin-top: 0.5rem;
}

.bt-grand-total-label {
	font-size: 1.125rem;
	font-weight: 800;
	color: var(--bt-navy-900);
}

.bt-grand-total-val {
	font-size: 1.35rem;
	font-weight: 900;
	color: var(--bt-blue-700);
}

.bt-sheet-footer {
	margin-top: 2.5rem;
	padding-top: 1rem;
	border-top: 1px solid var(--bt-slate-200);
	text-align: center;
}

.bt-sheet-footer-text {
	font-size: 0.75rem;
	color: var(--bt-slate-400);
	margin: 0;
}

/* ==========================================================================
   Tool Cards Grid (for archives, homepage, and related tools)
   ========================================================================== */
.bt-tools-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 1.5rem;
	margin: 2rem 0;
}

.bt-tool-card {
	background: #ffffff;
	border: 1px solid var(--bt-slate-200);
	border-radius: var(--bt-radius-lg);
	padding: 1.5rem;
	text-decoration: none;
	color: inherit;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	box-shadow: var(--bt-shadow-sm);
	transition: all 0.25s ease-in-out;
}

.bt-tool-card:hover {
	transform: translateY(-4px);
	box-shadow: var(--bt-shadow-lg);
	border-color: var(--bt-blue-500);
}

.bt-tool-card-icon {
	width: 44px;
	height: 44px;
	border-radius: var(--bt-radius-md);
	background: var(--bt-blue-50);
	color: var(--bt-blue-600);
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 1rem;
}

.bt-tool-card-title {
	font-size: 1.15rem;
	font-weight: 700;
	color: var(--bt-navy-900);
	margin: 0.5rem 0 0.5rem 0;
	line-height: 1.3;
}

.bt-tool-card-desc {
	font-size: 0.875rem;
	color: var(--bt-slate-600);
	margin: 0 0 1.25rem 0;
	line-height: 1.5;
}

.bt-tool-card-action {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	font-size: 0.875rem;
	font-weight: 700;
	color: var(--bt-blue-600);
}

.bt-tool-card:hover .bt-tool-card-action {
	color: var(--bt-blue-700);
}

/* ==========================================================================
   Ad Slots
   ========================================================================== */
.bt-ad-slot {
	margin: 2rem 0;
	text-align: center;
	clear: both;
}

.bt-ad-container {
	background: var(--bt-slate-50);
	border: 1px dashed var(--bt-slate-300);
	border-radius: var(--bt-radius-md);
	padding: 1rem;
	display: inline-block;
	max-width: 100%;
	box-sizing: border-box;
}

.bt-ad-label {
	display: block;
	font-size: 0.6875rem;
	font-weight: 600;
	color: var(--bt-slate-400);
	text-transform: uppercase;
	letter-spacing: 0.08em;
	margin-bottom: 0.5rem;
}

.bt-ad-placeholder {
	padding: 1.5rem 2.5rem;
	color: var(--bt-slate-500);
}

.bt-ad-slot-title {
	display: block;
	font-size: 0.875rem;
	font-weight: 700;
	color: var(--bt-slate-700);
}

.bt-ad-notice {
	display: block;
	font-size: 0.75rem;
	color: var(--bt-slate-400);
	margin-top: 0.25rem;
}

/* Toast Notifications */
.bt-toast {
	position: fixed;
	bottom: 2rem;
	right: 2rem;
	background: var(--bt-navy-900);
	color: #ffffff;
	padding: 0.75rem 1.25rem;
	border-radius: var(--bt-radius-md);
	box-shadow: 0 10px 25px rgba(0,0,0,0.25);
	font-size: 0.875rem;
	font-weight: 600;
	z-index: 99999;
	display: flex;
	align-items: center;
	gap: 0.5rem;
	opacity: 0;
	transform: translateY(10px);
	transition: all 0.3s ease-in-out;
	pointer-events: none;
}

.bt-toast.show {
	opacity: 1;
	transform: translateY(0);
}

/* ==========================================================================
   Tools Dark Mode Styles ([data-theme="dark"])
   ========================================================================== */
[data-theme="dark"] {
	--bt-navy-900: #f8fafc;
	--bt-navy-800: #f1f5f9;
	--bt-navy-700: #e2e8f0;
	--bt-slate-900: #f8fafc;
	--bt-slate-800: #f1f5f9;
	--bt-slate-700: #cbd5e1;
	--bt-slate-600: #94a3b8;
	--bt-slate-500: #94a3b8;
	--bt-slate-400: #64748b;
	--bt-slate-300: #334155;
	--bt-slate-200: #1e293b;
	--bt-slate-100: #131b2e;
	--bt-slate-50: #070b14;
	--bt-blue-50: rgba(37, 99, 235, 0.18);
	--bt-blue-100: rgba(37, 99, 235, 0.28);
	--bt-blue-200: rgba(37, 99, 235, 0.38);
}

[data-theme="dark"] .bt-calc-card {
	background: #0f172a;
	border-color: #1e293b;
	color: #cbd5e1;
}

[data-theme="dark"] .bt-calc-header-bar,
[data-theme="dark"] .bt-doc-top-bar {
	border-bottom-color: #1e293b;
}

[data-theme="dark"] .bt-label {
	color: #f8fafc;
}

[data-theme="dark"] .bt-input,
[data-theme="dark"] .bt-form-select {
	background-color: #131b2e;
	border-color: #334155;
	color: #f8fafc;
}

[data-theme="dark"] .bt-input:focus,
[data-theme="dark"] .bt-form-select:focus {
	border-color: #3b82f6;
	box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

[data-theme="dark"] .bt-input-wrapper {
	background-color: #131b2e;
	border-color: #334155;
}

[data-theme="dark"] .bt-input-wrapper:focus-within {
	border-color: #3b82f6;
	box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

[data-theme="dark"] .bt-input-wrapper .bt-input,
[data-theme="dark"] .bt-input-wrapper .bt-form-select {
	background-color: transparent !important;
	border: none !important;
	box-shadow: none !important;
	color: #f8fafc;
}

[data-theme="dark"] .bt-input-prefix,
[data-theme="dark"] .bt-input-suffix {
	background-color: #1e293b;
	color: #94a3b8;
	border-color: #334155;
}

[data-theme="dark"] .bt-results-card {
	background: #131b2e;
	border-color: #1e293b;
}

[data-theme="dark"] .bt-results-header {
	border-bottom-color: #1e293b;
}

[data-theme="dark"] .bt-results-heading {
	color: #f8fafc;
}

[data-theme="dark"] .bt-result-row {
	background: #1e293b;
	border-color: #334155;
}

[data-theme="dark"] .bt-result-row.bt-highlight-row {
	background: rgba(37, 99, 235, 0.2);
	border-color: #2563eb;
}

[data-theme="dark"] .bt-result-label {
	color: #94a3b8;
}

[data-theme="dark"] .bt-result-value {
	color: #f8fafc;
}

[data-theme="dark"] .bt-result-row.bt-highlight-row .bt-result-value {
	color: #93c5fd;
}

[data-theme="dark"] .bt-radio-label {
	color: #cbd5e1;
}

[data-theme="dark"] .bt-doc-paper-container {
	background: #070b14;
	border-color: #1e293b;
}

[data-theme="dark"] .bt-doc-sheet {
	background: #0f172a;
	color: #cbd5e1;
	border: 1px solid #1e293b;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .bt-sheet-title-input {
	color: #f8fafc;
}

[data-theme="dark"] .bt-sheet-type-heading {
	color: #f8fafc;
}

[data-theme="dark"] .bt-sheet-client-name {
	color: #f8fafc;
}

[data-theme="dark"] .bt-sheet-meta-input {
	color: #f8fafc;
}

[data-theme="dark"] .bt-sheet-table th {
	background: #1e293b;
	color: #f8fafc;
	border-bottom-color: #334155;
}

[data-theme="dark"] .bt-sheet-table td {
	border-bottom-color: #1e293b;
	color: #cbd5e1;
}

[data-theme="dark"] .bt-sheet-item-desc,
[data-theme="dark"] .bt-sheet-item-qty,
[data-theme="dark"] .bt-sheet-item-rate {
	color: #f8fafc;
}

[data-theme="dark"] .bt-sheet-textarea {
	color: #cbd5e1;
}

[data-theme="dark"] .bt-total-val {
	color: #f8fafc;
}

[data-theme="dark"] .bt-grand-total-label {
	color: #f8fafc;
}

[data-theme="dark"] .bt-grand-total-val {
	color: #60a5fa;
}

[data-theme="dark"] .bt-totals-row.bt-grand-total-row {
	border-top-color: #334155;
}

[data-theme="dark"] .bt-sheet-divider {
	border-top-color: #1e293b;
}

[data-theme="dark"] .bt-sheet-footer {
	border-top-color: #1e293b;
}

[data-theme="dark"] .bt-sheet-mini-input {
	background: #1e293b;
	border-color: #334155;
	color: #f8fafc;
}

[data-theme="dark"] .bt-btn-secondary {
	background: #1e293b;
	color: #e2e8f0;
	border-color: #334155;
}

[data-theme="dark"] .bt-btn-secondary:hover {
	background: #334155;
	color: #ffffff;
}

[data-theme="dark"] .bt-btn-subtle {
	border-color: #334155;
	color: #94a3b8;
}

[data-theme="dark"] .bt-btn-subtle:hover {
	background: #1e293b;
	color: #ffffff;
}

[data-theme="dark"] .bt-btn-icon {
	border-color: #334155;
	color: #94a3b8;
}

[data-theme="dark"] .bt-btn-icon:hover {
	background: #1e293b;
	color: #ffffff;
}

/* QR Code Section for Documents */
.bt-sheet-qr-section {
	margin-top: 1.25rem;
}

.bt-sheet-qr-section.bt-qr-hidden {
	display: none !important;
}

.bt-qr-card {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	background: #f8fafc;
	border: 1px solid var(--bt-slate-200);
	border-radius: var(--bt-radius-md);
	padding: 0.875rem;
}

@media (min-width: 500px) {
	.bt-qr-card {
		flex-direction: row;
		align-items: flex-start;
	}
}

.bt-qr-display-box {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.4rem;
	background: #ffffff;
	padding: 0.5rem;
	border: 1px solid var(--bt-slate-200);
	border-radius: var(--bt-radius-sm);
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
	flex-shrink: 0;
}

.bt-qr-canvas-holder {
	width: 110px;
	height: 110px;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.bt-qr-canvas-holder svg,
.bt-qr-canvas-holder img,
.bt-qr-canvas-holder canvas {
	display: block !important;
	width: 100% !important;
	height: 100% !important;
	max-width: 100% !important;
}

.bt-qr-badge {
	display: inline-block;
	font-size: 0.6875rem;
	font-weight: 700;
	color: var(--bt-blue-700);
	text-transform: uppercase;
	letter-spacing: 0.04em;
	text-align: center;
}

.bt-qr-config-panel {
	flex: 1;
	min-width: 0;
}

.bt-qr-toggle-label {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	font-size: 0.8125rem;
	color: var(--bt-slate-700);
	cursor: pointer;
	user-select: none;
}

.bt-sheet-mini-label {
	display: block;
	font-size: 0.75rem;
	font-weight: 600;
	color: var(--bt-slate-500);
	margin-bottom: 0.2rem;
}

.bt-sheet-mini-select {
	width: 100%;
	font-size: 0.8125rem;
	padding: 0.3rem 0.5rem;
	border-radius: 4px;
	border: 1px solid var(--bt-slate-300);
	background: #ffffff;
	color: var(--bt-slate-800);
	font-family: inherit;
}

.bt-qr-text-input {
	font-size: 0.8125rem;
	padding: 0.35rem 0.5rem;
	border: 1px solid var(--bt-slate-300);
	border-radius: 4px;
	width: 100%;
	box-sizing: border-box;
	background: #ffffff;
}

[data-theme="dark"] .bt-qr-card {
	background: #0f172a;
	border-color: #334155;
}

[data-theme="dark"] .bt-qr-display-box {
	background: #ffffff;
	border-color: #475569;
}

[data-theme="dark"] .bt-qr-toggle-label {
	color: #cbd5e1;
}

[data-theme="dark"] .bt-sheet-mini-label {
	color: #94a3b8;
}

[data-theme="dark"] .bt-sheet-mini-select,
[data-theme="dark"] .bt-qr-text-input {
	background: #1e293b;
	border-color: #334155;
	color: #f1f5f9;
}

[data-theme="dark"] .bt-calculator-wrapper,
[data-theme="dark"] .bt-document-generator-wrapper {
	color: #cbd5e1;
}

[data-theme="dark"] .bt-live-calc-tag,
[data-theme="dark"] .bt-live-saved-indicator {
	color: #94a3b8;
}

[data-theme="dark"] .bt-sheet-input {
	color: #f8fafc;
}

[data-theme="dark"] .bt-sheet-input:hover,
[data-theme="dark"] .bt-sheet-input:focus,
[data-theme="dark"] .bt-sheet-textarea:hover,
[data-theme="dark"] .bt-sheet-textarea:focus {
	border-color: #3b82f6;
	background-color: rgba(37, 99, 235, 0.2);
}

[data-theme="dark"] .bt-sheet-label,
[data-theme="dark"] .bt-total-label,
[data-theme="dark"] .bt-meta-row label {
	color: #94a3b8;
}

[data-theme="dark"] .bt-sheet-section-tag {
	color: #64748b;
}

[data-theme="dark"] input::placeholder,
[data-theme="dark"] textarea::placeholder {
	color: #64748b;
	opacity: 1;
}

[data-theme="dark"] .bt-results-empty-state {
	color: #94a3b8;
}

[data-theme="dark"] .bt-empty-icon svg {
	stroke: #64748b;
}

[data-theme="dark"] .bt-tool-card {
	background: #0f172a;
	border-color: #1e293b;
	color: #cbd5e1;
}

[data-theme="dark"] .bt-tool-card:hover {
	border-color: #3b82f6;
	background: #131b2e;
}

[data-theme="dark"] .bt-tool-card-title {
	color: #f8fafc;
}

[data-theme="dark"] .bt-tool-card-desc {
	color: #94a3b8;
}

[data-theme="dark"] .bt-tool-card-icon {
	background: rgba(37, 99, 235, 0.2);
	color: #60a5fa;
}

[data-theme="dark"] .bt-ad-container {
	background: #0f172a;
	border-color: #334155;
}

[data-theme="dark"] .bt-ad-slot-title {
	color: #cbd5e1;
}

[data-theme="dark"] .bt-ad-label,
[data-theme="dark"] .bt-ad-notice,
[data-theme="dark"] .bt-ad-placeholder {
	color: #64748b;
}

[data-theme="dark"] .bt-btn-outline {
	color: #60a5fa;
	border-color: #3b82f6;
}

[data-theme="dark"] .bt-btn-outline:hover {
	background-color: rgba(37, 99, 235, 0.2);
	color: #93c5fd;
}

[data-theme="dark"] .bt-badge-navy {
	background-color: #1e293b;
	color: #f8fafc;
	border: 1px solid #334155;
}

[data-theme="dark"] .bt-toast {
	background: #1e293b;
	color: #ffffff;
	border: 1px solid #334155;
}

[data-theme="dark"] .bt-form-help {
	color: #94a3b8 !important;
}



