/* ===== INVOICE GENERATOR - CalcTechLab ===== */

.inv-app {
    max-width: 1400px;
    margin: 0 auto;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ===== ACTIONS BAR ===== */
.inv-actions-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}
[data-bs-theme="dark"] .inv-actions-bar {
    background: #1e293b;
    border-color: #334155;
}

.inv-actions-left, .inv-actions-right {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.inv-action-btn {
    padding: 0.55rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    background: white;
    color: #475569;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}
[data-bs-theme="dark"] .inv-action-btn {
    background: #0f172a;
    border-color: #334155;
    color: #94a3b8;
}
.inv-action-btn:hover {
    border-color: #3b82f6;
    color: #3b82f6;
    transform: translateY(-1px);
}

.inv-action-primary {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    border-color: #3b82f6;
}
.inv-action-primary:hover {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.inv-action-danger {
    color: #ef4444;
    border-color: #fecaca;
}
.inv-action-danger:hover {
    background: #fef2f2;
    border-color: #ef4444;
    color: #ef4444;
}
[data-bs-theme="dark"] .inv-action-danger:hover {
    background: #450a0a;
}

/* ===== CARDS ===== */
.inv-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 1.75rem;
    margin-bottom: 1.25rem;
    border: 1px solid #e2e8f0;
    transition: box-shadow 0.3s ease;
}
[data-bs-theme="dark"] .inv-card {
    background: #1e293b;
    border-color: #334155;
}

.inv-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 1rem;
}
[data-bs-theme="dark"] .inv-card-title {
    color: #f1f5f9;
}

/* ===== FORM FIELDS ===== */
.inv-settings-grid {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.inv-fields-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.85rem;
}

.inv-field {
    min-width: 0;
}

.inv-field-full {
    grid-column: 1 / -1;
}

.inv-label {
    display: block;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
    margin-bottom: 0.35rem;
}

.inv-input {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    color: #1e293b;
    background: #f8fafc;
    transition: all 0.2s;
    box-sizing: border-box;
}
[data-bs-theme="dark"] .inv-input {
    background: #0f172a;
    border-color: #334155;
    color: #f1f5f9;
}
.inv-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
    background: white;
}
[data-bs-theme="dark"] .inv-input:focus {
    background: #1e293b;
}

.inv-input-sm {
    width: 90px;
    text-align: center;
    font-weight: 600;
}

.inv-select {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    color: #1e293b;
    background: #f8fafc;
    cursor: pointer;
    transition: all 0.2s;
}
[data-bs-theme="dark"] .inv-select {
    background: #0f172a;
    border-color: #334155;
    color: #f1f5f9;
}

.inv-select-sm {
    width: 70px;
}

.inv-textarea {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    color: #1e293b;
    background: #f8fafc;
    resize: vertical;
    font-family: inherit;
    transition: all 0.2s;
    box-sizing: border-box;
}
[data-bs-theme="dark"] .inv-textarea {
    background: #0f172a;
    border-color: #334155;
    color: #f1f5f9;
}
.inv-textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
}

/* ===== THEME SELECTOR ===== */
.inv-theme-grid {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
    padding-top: 0.25rem;
}

.inv-theme-btn {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: 3px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
}
.inv-theme-btn:hover {
    transform: scale(1.15);
}
.inv-theme-btn.active {
    border-color: #1e293b;
    box-shadow: 0 0 0 2px white;
}
[data-bs-theme="dark"] .inv-theme-btn.active {
    border-color: #f1f5f9;
    box-shadow: 0 0 0 2px #0f172a;
}

/* ===== LOGO ===== */
.inv-from-layout {
    display: flex;
    gap: 1.25rem;
}

.inv-logo-area {
    width: 140px;
    flex-shrink: 0;
}

.inv-logo-drop {
    width: 140px;
    height: 100px;
    border: 2px dashed #cbd5e1;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    overflow: hidden;
    position: relative;
}
[data-bs-theme="dark"] .inv-logo-drop {
    border-color: #475569;
}
.inv-logo-drop:hover, .inv-logo-drop.dragover {
    border-color: #3b82f6;
    background: #eff6ff;
}
[data-bs-theme="dark"] .inv-logo-drop:hover,
[data-bs-theme="dark"] .inv-logo-drop.dragover {
    background: #1e3a5f;
}

.inv-logo-placeholder {
    text-align: center;
    color: #94a3b8;
}
.inv-logo-placeholder i {
    font-size: 1.5rem;
    display: block;
    margin-bottom: 0.25rem;
}
.inv-logo-placeholder span {
    display: block;
    font-size: 0.6rem;
    font-weight: 600;
}
.inv-logo-hint {
    color: #cbd5e1;
    font-size: 0.55rem !important;
}

.inv-logo-preview {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 4px;
}

.inv-logo-remove {
    width: 100%;
    padding: 0.3rem;
    border: none;
    background: transparent;
    color: #ef4444;
    font-size: 0.65rem;
    font-weight: 600;
    cursor: pointer;
    margin-top: 0.25rem;
    border-radius: 6px;
}
.inv-logo-remove:hover {
    background: #fef2f2;
}

.inv-from-fields {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    min-width: 0;
}

/* ===== LINE ITEMS TABLE ===== */
.inv-items-table-wrap {
    overflow-x: auto;
    margin-bottom: 1rem;
}

.inv-items-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 500px;
}

.inv-items-table th {
    padding: 0.6rem 0.5rem;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #64748b;
    border-bottom: 2px solid #e2e8f0;
    text-align: left;
}
[data-bs-theme="dark"] .inv-items-table th {
    border-color: #334155;
}

.inv-th-desc { width: 45%; }
.inv-th-qty { width: 12%; }
.inv-th-rate { width: 18%; }
.inv-th-amount { width: 18%; }
.inv-th-action { width: 7%; }

.inv-items-table td {
    padding: 0.4rem 0.35rem;
    vertical-align: top;
}

.inv-items-table tbody tr {
    border-bottom: 1px solid #f1f5f9;
}
[data-bs-theme="dark"] .inv-items-table tbody tr {
    border-color: #1e293b;
}

.inv-item-input {
    width: 100%;
    padding: 0.5rem 0.5rem;
    border: 2px solid transparent;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 500;
    color: #1e293b;
    background: transparent;
    transition: all 0.2s;
    box-sizing: border-box;
}
[data-bs-theme="dark"] .inv-item-input {
    color: #f1f5f9;
}
.inv-item-input:hover {
    background: #f8fafc;
}
[data-bs-theme="dark"] .inv-item-input:hover {
    background: #0f172a;
}
.inv-item-input:focus {
    outline: none;
    border-color: #3b82f6;
    background: white;
}
[data-bs-theme="dark"] .inv-item-input:focus {
    background: #0f172a;
}

.inv-item-input-num {
    text-align: right;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
}

.inv-item-amount {
    text-align: right;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    font-size: 0.8rem;
    color: #1e293b;
    padding: 0.5rem;
}
[data-bs-theme="dark"] .inv-item-amount {
    color: #f1f5f9;
}

.inv-item-remove {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: #cbd5e1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    transition: all 0.2s;
}
.inv-item-remove:hover {
    background: #fef2f2;
    color: #ef4444;
}
[data-bs-theme="dark"] .inv-item-remove:hover {
    background: #450a0a;
}

.inv-add-item-btn {
    width: 100%;
    padding: 0.65rem;
    border: 2px dashed #cbd5e1;
    border-radius: 10px;
    background: transparent;
    color: #64748b;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
[data-bs-theme="dark"] .inv-add-item-btn {
    border-color: #475569;
    color: #94a3b8;
}
.inv-add-item-btn:hover {
    border-color: #3b82f6;
    color: #3b82f6;
    background: #eff6ff;
}
[data-bs-theme="dark"] .inv-add-item-btn:hover {
    background: #1e3a5f;
}

/* ===== TOTALS EDITOR ===== */
.inv-totals-editor {
    margin-bottom: 1.25rem;
}

.inv-adjustment-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid #f1f5f9;
}
[data-bs-theme="dark"] .inv-adjustment-row {
    border-color: #1e293b;
}

.inv-adj-label {
    width: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
    flex-shrink: 0;
}
[data-bs-theme="dark"] .inv-adj-label {
    color: #94a3b8;
}

.inv-adj-controls {
    display: flex;
    gap: 0.4rem;
    align-items: center;
    flex: 1;
}

.inv-toggle-tax2 {
    padding: 0.35rem 0.75rem;
    border: none;
    background: transparent;
    color: #3b82f6;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    margin-top: 0.25rem;
}
.inv-toggle-tax2:hover {
    text-decoration: underline;
}

/* ===== TOTALS DISPLAY ===== */
.inv-totals-display {
    border-top: 2px solid #e2e8f0;
    padding-top: 1rem;
}
[data-bs-theme="dark"] .inv-totals-display {
    border-color: #334155;
}

.inv-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.4rem 0;
    font-size: 0.85rem;
    color: #475569;
}
[data-bs-theme="dark"] .inv-total-row {
    color: #94a3b8;
}

.inv-total-row span:last-child {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    color: #1e293b;
}
[data-bs-theme="dark"] .inv-total-row span:last-child {
    color: #f1f5f9;
}

.inv-total-grand {
    border-top: 2px solid #1e293b;
    margin-top: 0.5rem;
    padding-top: 0.75rem;
    font-size: 1.1rem;
    font-weight: 800;
    color: #1e293b;
}
[data-bs-theme="dark"] .inv-total-grand {
    border-color: #f1f5f9;
    color: #f1f5f9;
}

.inv-total-grand span:last-child {
    font-size: 1.25rem;
    color: #3b82f6;
}

/* ===== LIVE PREVIEW ===== */
.inv-preview-sticky {
    position: sticky;
    top: 80px;
}

.inv-preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.inv-preview-zoom {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.inv-zoom-btn {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    background: white;
    color: #64748b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    transition: all 0.2s;
}
[data-bs-theme="dark"] .inv-zoom-btn {
    background: #0f172a;
    border-color: #334155;
    color: #94a3b8;
}
.inv-zoom-btn:hover {
    border-color: #3b82f6;
    color: #3b82f6;
}

.inv-zoom-level {
    font-size: 0.7rem;
    font-weight: 700;
    color: #64748b;
    min-width: 35px;
    text-align: center;
}

.inv-preview-scroll {
    max-height: calc(100vh - 180px);
    overflow-y: auto;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #94a3b8;
    padding: 1rem;
}
[data-bs-theme="dark"] .inv-preview-scroll {
    background: #0f172a;
    border-color: #334155;
}

.inv-preview-wrapper {
    transform-origin: top center;
    transition: transform 0.2s;
}

/* ===== THE INVOICE (PDF) ===== */
.inv-invoice {
    background: white;
    color: #1e293b;
    padding: 2.5rem;
    border-radius: 4px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    font-family: 'Inter', -apple-system, sans-serif;
    font-size: 10px;
    line-height: 1.5;
    min-height: 800px;
}

.inv-inv-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 3px solid #3b82f6;
}

.inv-inv-header-left {
    flex: 1;
}

.inv-inv-logo {
    max-width: 150px;
    max-height: 60px;
    object-fit: contain;
    margin-bottom: 0.75rem;
}

.inv-inv-from-name {
    font-size: 16px;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 0.25rem;
}

.inv-inv-from-details {
    font-size: 9px;
    color: #64748b;
    line-height: 1.6;
    white-space: pre-line;
}

.inv-inv-header-right {
    text-align: right;
}

.inv-inv-title {
    font-size: 28px;
    font-weight: 900;
    color: #3b82f6;
    letter-spacing: 0.05em;
    line-height: 1;
    margin-bottom: 0.35rem;
}

.inv-inv-number {
    font-size: 12px;
    font-weight: 700;
    color: #475569;
}

.inv-inv-status {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 8px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.35rem;
}

.inv-inv-status-draft { background: #f1f5f9; color: #64748b; }
.inv-inv-status-sent { background: #dbeafe; color: #2563eb; }
.inv-inv-status-paid { background: #dcfce7; color: #16a34a; }
.inv-inv-status-overdue { background: #fef2f2; color: #dc2626; }
.inv-inv-status-cancelled { background: #f1f5f9; color: #94a3b8; }

/* Meta */
.inv-inv-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    gap: 2rem;
}

.inv-inv-meta-left {
    flex: 1;
}

.inv-inv-meta-label {
    font-size: 8px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94a3b8;
    margin-bottom: 0.35rem;
}

.inv-inv-to-name {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.15rem;
}

.inv-inv-to-details {
    font-size: 9px;
    color: #64748b;
    line-height: 1.6;
    white-space: pre-line;
}

.inv-inv-meta-right {
    min-width: 180px;
}

.inv-inv-meta-row {
    display: flex;
    justify-content: space-between;
    padding: 0.2rem 0;
    font-size: 9px;
    gap: 1rem;
}

.inv-inv-meta-row span:first-child {
    color: #94a3b8;
    font-weight: 600;
}

.inv-inv-meta-row span:last-child {
    color: #1e293b;
    font-weight: 700;
    text-align: right;
}

/* Items Table */
.inv-inv-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
}

.inv-inv-table thead th {
    padding: 0.6rem 0.5rem;
    font-size: 8px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: white;
    background: #3b82f6;
    text-align: left;
}

.inv-inv-table thead th:nth-child(2),
.inv-inv-table thead th:nth-child(3),
.inv-inv-table thead th:nth-child(4) {
    text-align: right;
}

.inv-inv-table tbody td {
    padding: 0.5rem;
    font-size: 9px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: top;
}

.inv-inv-table tbody td:nth-child(2),
.inv-inv-table tbody td:nth-child(3),
.inv-inv-table tbody td:nth-child(4) {
    text-align: right;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    white-space: nowrap;
}

.inv-inv-table tbody tr:last-child td {
    border-bottom: none;
}

/* Totals */
.inv-inv-totals {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1.5rem;
}

.inv-inv-totals-inner {
    width: 220px;
}

.inv-inv-total-row {
    display: flex;
    justify-content: space-between;
    padding: 0.25rem 0;
    font-size: 9px;
}

.inv-inv-total-row span:first-child {
    color: #64748b;
}

.inv-inv-total-row span:last-child {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    color: #1e293b;
}

.inv-inv-total-grand {
    border-top: 2px solid #1e293b;
    margin-top: 0.35rem;
    padding-top: 0.5rem;
    font-size: 12px;
    font-weight: 800;
}

.inv-inv-total-grand span:last-child {
    color: #3b82f6;
    font-size: 14px;
}

/* Notes */
.inv-inv-notes, .inv-inv-payment, .inv-inv-terms {
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #f8fafc;
    border-radius: 6px;
    border-left: 3px solid #3b82f6;
}

.inv-inv-notes-title, .inv-inv-payment-title {
    font-size: 9px;
    font-weight: 700;
    text-transform: uppercase;
    color: #3b82f6;
    margin-bottom: 0.25rem;
}

.inv-inv-notes-text, .inv-inv-payment-text {
    font-size: 9px;
    color: #475569;
    white-space: pre-line;
    line-height: 1.6;
}

.inv-inv-terms {
    background: transparent;
    border-left: none;
    padding: 0;
}

.inv-inv-terms-text {
    font-size: 7px;
    color: #94a3b8;
    line-height: 1.5;
    white-space: pre-line;
}

/* Footer */
.inv-inv-footer {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
    font-size: 7px;
    color: #cbd5e1;
}

/* ===== MODAL ===== */
.inv-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.inv-modal {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 550px;
    max-height: 80vh;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}
[data-bs-theme="dark"] .inv-modal {
    background: #1e293b;
}

.inv-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid #e2e8f0;
}
[data-bs-theme="dark"] .inv-modal-header {
    border-color: #334155;
}

.inv-modal-header h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
}
[data-bs-theme="dark"] .inv-modal-header h3 {
    color: #f1f5f9;
}

.inv-modal-close {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: none;
    background: #f1f5f9;
    color: #64748b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
[data-bs-theme="dark"] .inv-modal-close {
    background: #334155;
    color: #94a3b8;
}
.inv-modal-close:hover {
    background: #fef2f2;
    color: #ef4444;
}

.inv-modal-body {
    padding: 1.25rem 1.5rem;
    max-height: 60vh;
    overflow-y: auto;
}

.inv-modal-empty {
    text-align: center;
    padding: 2rem;
    color: #94a3b8;
}
.inv-modal-empty i {
    font-size: 2rem;
    display: block;
    margin-bottom: 0.75rem;
    opacity: 0.4;
}

.inv-saved-invoice-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    margin-bottom: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
}
[data-bs-theme="dark"] .inv-saved-invoice-item {
    border-color: #334155;
}
.inv-saved-invoice-item:hover {
    border-color: #3b82f6;
    background: #eff6ff;
}
[data-bs-theme="dark"] .inv-saved-invoice-item:hover {
    background: #1e3a5f;
}

.inv-saved-invoice-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: #eff6ff;
    color: #3b82f6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
}
[data-bs-theme="dark"] .inv-saved-invoice-icon {
    background: #1e3a5f;
}

.inv-saved-invoice-info {
    flex: 1;
    min-width: 0;
}

.inv-saved-invoice-number {
    font-size: 0.85rem;
    font-weight: 700;
    color: #1e293b;
}
[data-bs-theme="dark"] .inv-saved-invoice-number {
    color: #f1f5f9;
}

.inv-saved-invoice-meta {
    font-size: 0.7rem;
    color: #64748b;
}

.inv-saved-invoice-amount {
    font-size: 0.9rem;
    font-weight: 800;
    font-family: 'JetBrains Mono', monospace;
    color: #3b82f6;
    flex-shrink: 0;
}

.inv-saved-invoice-delete {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: #cbd5e1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    flex-shrink: 0;
    transition: all 0.2s;
}
.inv-saved-invoice-delete:hover {
    background: #fef2f2;
    color: #ef4444;
}

/* ===== FAQ ===== */
.inv-faq-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.inv-faq-item {
    padding: 1rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
}
[data-bs-theme="dark"] .inv-faq-item {
    background: #0f172a;
    border-color: #334155;
}

.inv-faq-item h3 {
    font-size: 0.85rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 0.35rem;
}
[data-bs-theme="dark"] .inv-faq-item h3 {
    color: #f1f5f9;
}

.inv-faq-item p {
    font-size: 0.78rem;
    color: #64748b;
    line-height: 1.6;
    margin: 0;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 991.98px) {
    .inv-preview-sticky {
        position: static;
    }
    .inv-preview-scroll {
        max-height: none;
    }
}

@media (max-width: 767.98px) {
    .inv-card {
        padding: 1.25rem;
    }
    .inv-actions-bar {
        flex-direction: column;
    }
    .inv-actions-left, .inv-actions-right {
        width: 100%;
        justify-content: center;
    }
    .inv-from-layout {
        flex-direction: column;
    }
    .inv-logo-area {
        width: 100%;
    }
    .inv-logo-drop {
        width: 100%;
    }
    .inv-from-fields {
        grid-template-columns: 1fr;
    }
    .inv-fields-grid {
        grid-template-columns: 1fr;
    }
    .inv-field-full {
        grid-column: 1;
    }
    .inv-invoice {
        padding: 1.5rem;
        font-size: 8px;
    }
    .inv-inv-header {
        flex-direction: column;
        gap: 1rem;
    }
    .inv-inv-header-right {
        text-align: left;
    }
    .inv-inv-title {
        font-size: 22px;
    }
    .inv-inv-meta {
        flex-direction: column;
        gap: 1rem;
    }
    .inv-faq-list {
        grid-template-columns: 1fr;
    }
    .inv-settings-grid {
        flex-direction: column;
    }
    .inv-adj-controls {
        flex-wrap: wrap;
    }
}

/* ===== PRINT ===== */
@media print {
    .inv-actions-bar,
    .inv-preview-header,
    .inv-preview-zoom,
    .col-lg-7,
    .inv-faq-list,
    .inv-modal-overlay,
    nav, footer,
    .calculator-breadcrumb,
    .calculator-page-header,
    .fullscreen-toggle-btn {
        display: none !important;
    }
    .col-lg-5 {
        width: 100% !important;
        max-width: 100% !important;
        flex: 0 0 100% !important;
    }
    .inv-preview-scroll {
        border: none;
        background: none;
        padding: 0;
        max-height: none;
        overflow: visible;
    }
    .inv-preview-sticky {
        position: static;
    }
    .inv-invoice {
        box-shadow: none;
        border-radius: 0;
    }
}
