* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #1a1a1a;
    --primary-dark: #000000;
    --secondary: #4a4a4a;
    --danger: #ef4444;
    --warning: #f59e0b;
    --success: #10b981;
    --light: #f9fafb;
    --border: #e5e7eb;
    --text: #1f2937;
    --text-light: #6b7280;
    --shadow: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.2);
    --transition: all 0.3s ease;
}

html, body {
    height: 100%;
    width: 100%;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f5f5 0%, #e0e0e0 100%);
    color: var(--text);
    min-height: 100vh;
    overflow: hidden;
}

.app-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    background: var(--light);
}

/* Header */
.header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 0;
    box-shadow: var(--shadow-lg);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.header h1 {
    font-size: 24px;
    font-weight: 700;
}

.sync-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
}

.sync-indicator {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 20px;
    background: rgba(255,255,255,0.2);
}

.sync-indicator::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    animation: pulse 2s infinite;
}

.sync-indicator.offline::before {
    background: #ef4444;
    animation: none;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Navigation Tabs */
.nav-tabs {
    display: flex;
    overflow-x: auto;
    border-bottom: 2px solid rgba(255,255,255,0.1);
}

.nav-tab {
    flex: 1;
    padding: 12px 16px;
    background: none;
    border: none;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    transition: var(--transition);
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
}

.nav-tab:hover {
    background: rgba(255,255,255,0.1);
    color: white;
}

.nav-tab.active {
    color: white;
    background: rgba(255,255,255,0.2);
    border-bottom-color: white;
    font-weight: 600;
}

/* Main Content */
.main-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Section Header */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-header h2 {
    font-size: 24px;
    color: var(--text);
}

/* Dashboard */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 15px;
    transition: var(--transition);
    border-left: 5px solid var(--primary);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.stat-icon {
    font-size: 40px;
}

.stat-content {
    flex: 1;
}

.stat-label {
    font-size: 12px;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    margin-top: 5px;
}

.dashboard-sections {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.dashboard-section {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow);
}

.dashboard-section h2 {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--primary);
}

.expenses-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.expense-item {
    padding: 12px;
    background: var(--light);
    border-left: 4px solid var(--primary);
    border-radius: 6px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.expense-item-info {
    flex: 1;
}

.expense-item-company {
    font-size: 12px;
    color: var(--text-light);
}

.expense-item-desc {
    font-weight: 500;
    margin: 3px 0;
}

.expense-item-amount {
    font-weight: 700;
    color: var(--primary);
    font-size: 16px;
}

/* Category Stats */
.category-stats {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.category-stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: var(--light);
    border-radius: 6px;
}

.category-stat-name {
    font-weight: 500;
}

.category-stat-amount {
    font-weight: 700;
    color: var(--primary);
}

/* Companies */
.companies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.company-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    border-left: 5px solid var(--primary);
}

.company-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.company-card-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 15px;
}

.company-card-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text);
    flex: 1;
}

.company-card-actions {
    display: flex;
    gap: 8px;
}

.company-card-actions button {
    width: 32px;
    height: 32px;
    padding: 0;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.company-card-info {
    font-size: 14px;
    margin-bottom: 8px;
}

.company-card-label {
    color: var(--text-light);
    font-size: 12px;
}

.company-card-value {
    color: var(--text);
    font-weight: 500;
}

/* Expenses Table */
.filters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.expenses-table {
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow);
    overflow: hidden;
}

.table-header {
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr 1fr 1fr 80px;
    gap: 12px;
    padding: 15px 20px;
    background: var(--light);
    font-weight: 600;
    font-size: 13px;
    color: var(--text-light);
    border-bottom: 2px solid var(--border);
}

.table-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr 1fr 1fr 80px;
    gap: 12px;
    padding: 15px 20px;
    border-bottom: 1px solid var(--border);
    align-items: center;
}

.table-row:hover {
    background: var(--light);
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-pending {
    background: #fef3c7;
    color: #92400e;
}

.status-approved {
    background: #dbeafe;
    color: #0c4a6e;
}

.status-paid {
    background: #dcfce7;
    color: #166534;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-primary {
    background: var(--primary);
    color: white;
    border: 2px solid var(--primary-dark);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-secondary {
    background: #e5e5e5;
    color: var(--primary);
    border: 2px solid #cccccc;
}

.btn-secondary:hover {
    background: #d0d0d0;
    border-color: var(--primary);
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
}

.btn-small {
    padding: 6px 12px;
    font-size: 12px;
}

/* Forms */
.form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.form-group label {
    font-weight: 600;
    font-size: 13px;
    color: var(--text);
}

.form-control {
    padding: 10px 12px;
    border: 2px solid var(--border);
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
}

.form-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 15px;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 200;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    padding: 20px;
    border-bottom: 2px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    color: var(--text);
}

.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: var(--text-light);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--text);
}

.modal-content .form {
    padding: 20px;
}

/* Toast */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: white;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    display: none;
    z-index: 300;
    animation: slideIn 0.3s ease;
}

.toast.show {
    display: block;
}

.toast.success {
    border-left: 4px solid var(--success);
    color: var(--text);
}

.toast.error {
    border-left: 4px solid var(--danger);
    color: var(--text);
}

@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Reports */
.reports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.report-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow);
}

.report-card h3 {
    margin-bottom: 15px;
    color: var(--primary);
}

.chart-container {
    min-height: 300px;
    display: flex;
    flex-direction: column;
}

.chart-bar {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.chart-label {
    width: 120px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text);
}

.chart-fill {
    flex: 1;
    height: 20px;
    background: linear-gradient(90deg, var(--primary), var(--primary-dark));
    border-radius: 4px;
    margin: 0 10px;
}

.chart-value {
    width: 80px;
    text-align: right;
    font-weight: 600;
    color: var(--primary);
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-light);
    font-style: italic;
}

/* Responsive */
@media (max-width: 768px) {
    .dashboard-sections {
        grid-template-columns: 1fr;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .companies-grid {
        grid-template-columns: 1fr;
    }

    .table-header,
    .table-row {
        grid-template-columns: 1fr;
    }

    .nav-tabs {
        overflow-x: auto;
        scroll-behavior: smooth;
    }

    .nav-tab {
        min-width: 100px;
        padding: 10px 12px;
        font-size: 12px;
    }

    .filters {
        grid-template-columns: 1fr;
    }

    .reports-grid {
        grid-template-columns: 1fr;
    }

    .modal-content {
        width: 95%;
        max-height: 95vh;
    }

    .toast {
        left: 10px;
        right: 10px;
        bottom: 10px;
    }
}

/* Payment Form Styles */
.payment-form-container {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    overflow-y: auto;
    max-height: calc(100vh - 180px);
}

.payment-container {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 11pt;
}

.payment-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #cccccc;
    gap: 10px;
}

.lang-buttons {
    display: flex;
    gap: 5px;
}

.lang-buttons button {
    padding: 6px 12px;
    font-size: 10pt;
}

.lang-buttons button.active {
    background: var(--primary);
    color: white;
}

.payment-header {
    text-align: center;
    margin-bottom: 20px;
    padding: 15px;
    background: linear-gradient(135deg, #f5f5f5 0%, #e0e0e0 100%);
    border-bottom: 3px solid var(--primary);
    border-radius: 6px;
}

.payment-header h1 {
    font-size: 24pt;
    color: var(--primary);
    margin-bottom: 5px;
}

.payment-header h2 {
    font-size: 12pt;
    font-weight: 300;
    color: #666;
}

.doc-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.payment-section {
    margin-bottom: 20px;
    background: #fafafa;
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid var(--primary);
}

.payment-section .section-title {
    font-size: 11pt;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group {
    margin-bottom: 12px;
}

.form-group label {
    display: block;
    font-weight: 600;
    font-size: 10pt;
    color: #4b5563;
    margin-bottom: 6px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 8px 10px;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    font-size: 10pt;
    font-family: inherit;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 50px;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.contract-box {
    background: white;
    border: 2px solid #cccccc;
    padding: 15px;
    border-radius: 8px;
    margin: 10px 0;
}

.contract-header {
    display: grid;
    grid-template-columns: 1fr 110px 60px 100px 100px 30px;
    gap: 8px;
    font-weight: 700;
    font-size: 9pt;
    color: var(--primary);
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
    margin-bottom: 12px;
    align-items: center;
}

.grid-4 {
    display: grid;
    grid-template-columns: 1fr 110px 60px 100px 100px 30px;
    gap: 6px;
    align-items: center;
    margin-bottom: 8px;
}

.grid-4 input[type="text"],
.grid-4 select {
    padding: 6px 8px;
    font-size: 9pt;
    border: 2px solid #e5e7eb;
    border-radius: 4px;
}

.amount-box {
    display: flex;
    align-items: center;
    border: 2px solid #e5e7eb;
    border-radius: 4px;
    overflow: hidden;
    background: white;
}

.amount-box input {
    flex: 1;
    border: none;
    padding: 6px 8px;
    text-align: right;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    font-size: 9pt;
}

.amount-box input:focus {
    outline: none;
    background: #fafafa;
}

.amount-box span {
    background: var(--primary);
    color: white;
    padding: 6px 10px;
    font-weight: 700;
    font-size: 8pt;
    white-space: nowrap;
}

.contract-total {
    display: grid;
    grid-template-columns: 1fr 110px 60px 100px 100px 30px;
    gap: 8px;
    font-weight: 700;
    padding-top: 10px;
    margin-top: 10px;
    border-top: 2px solid var(--primary);
    align-items: center;
}

.payment-box {
    background: white;
    border: 2px solid var(--primary);
    padding: 15px;
    border-radius: 8px;
    margin: 10px 0;
}

.payment-total {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 2px solid var(--primary);
}

.work-item {
    display: grid;
    grid-template-columns: 1fr 120px 30px;
    gap: 8px;
    margin-bottom: 8px;
    align-items: center;
}

.work-item input,
.work-item select {
    padding: 6px 8px;
    border: 2px solid #e5e7eb;
    border-radius: 4px;
    font-size: 9pt;
}

.btn-small {
    width: 30px;
    height: 30px;
    padding: 0;
    font-size: 14pt;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-small:hover {
    background: #dc2626;
}

.amount-box.total input {
    font-size: 11pt;
    font-weight: 700;
}

.signatures {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.signature-box {
    text-align: center;
}

.signature-line {
    border-top: 2px solid var(--primary);
    padding-top: 10px;
    margin-top: 50px;
    font-weight: 600;
    color: var(--primary);
}

.signature-title {
    font-size: 9pt;
    color: #6b7280;
    margin-top: 4px;
}

/* STEP-BY-STEP PAYMENT FORM STYLES */

.payment-form-wrapper {
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 180px);
}

.form-steps-indicator {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0 30px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--border);
}

.step-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    flex: 1;
    opacity: 0.5;
    transition: var(--transition);
}

.step-badge.active {
    opacity: 1;
}

.step-num {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 18px;
    color: var(--text-light);
    transition: var(--transition);
}

.step-badge.active .step-num {
    background: var(--primary);
    color: white;
}

.step-name {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-light);
}

.step-connector {
    flex: 1;
    height: 2px;
    background: var(--border);
    margin: 0 10px;
    margin-top: 20px;
}

.payment-form-content {
    flex: 1;
    overflow-y: auto;
    padding-right: 10px;
}

.step-form {
    display: none;
    animation: slideIn 0.3s ease;
}

.step-form.active {
    display: block;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.step-form h3 {
    color: var(--primary);
    margin-bottom: 20px;
    font-size: 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border);
}

.step-form h4 {
    color: var(--secondary);
    margin-top: 20px;
    margin-bottom: 12px;
    font-size: 14px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-field label {
    font-weight: 600;
    font-size: 13px;
    color: var(--text);
}

.form-input {
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 13px;
    transition: var(--transition);
    font-family: inherit;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.text-large {
    font-size: 20px !important;
    font-weight: bold !important;
}

/* Contract Table */
.contract-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 15px;
    background: white;
}

.contract-table thead th {
    background: var(--light);
    padding: 12px;
    text-align: left;
    font-weight: 600;
    font-size: 12px;
    color: var(--text);
    border-bottom: 2px solid var(--border);
}

.contract-table tbody td {
    padding: 10px;
    border-bottom: 1px solid var(--border);
}

.contract-row td input,
.contract-row td select {
    width: 100%;
    padding: 8px;
    border: 1px solid var(--border);
    border-radius: 4px;
    font-size: 12px;
}

.contract-row td input:focus,
.contract-row td select:focus {
    outline: none;
    border-color: var(--primary);
    background: #fafafa;
}

.contract-total {
    background: #fafafa;
    font-weight: bold;
}

.contract-total td {
    border: 2px solid var(--border);
    padding: 12px;
}

.contract-total input {
    background: #fff !important;
    border: 1px solid var(--border) !important;
    padding: 8px !important;
}

/* Work Items */
.work-item-row {
    display: grid;
    grid-template-columns: 1fr 120px 40px;
    gap: 10px;
    align-items: center;
    margin-bottom: 10px;
    padding: 10px;
    background: var(--light);
    border-radius: 6px;
}

/* Payment Summary */
.payment-summary-box {
    background: linear-gradient(135deg, #f0f0f0 0%, #fafafa 100%);
    border: 2px solid var(--border);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.summary-item:last-child {
    border-bottom: none;
}

.summary-item span {
    font-weight: 600;
    color: var(--text);
}

.summary-item input {
    text-align: right;
    font-weight: bold;
    border: none !important;
    background: transparent !important;
    color: var(--text);
}

.summary-item.total {
    background: var(--primary);
    color: white;
    padding: 15px;
    margin: 0 -20px -20px -20px;
    border-radius: 0 0 6px 6px;
}

.summary-item.total span {
    color: white;
}

.summary-item.total input {
    color: white;
}

/* Approval Preview */
.approval-preview {
    background: var(--light);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 15px;
    margin-top: 20px;
    margin-bottom: 20px;
}

.approval-preview h4 {
    margin-top: 0;
    color: var(--primary);
}

.preview-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.preview-row {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    background: white;
    border-radius: 4px;
    border-left: 3px solid var(--border);
}

.preview-row.highlight {
    background: #fffbea;
    border-left-color: var(--warning);
}

.preview-row span {
    color: var(--text-light);
    font-weight: 500;
}

.preview-row strong {
    color: var(--text);
    font-weight: 700;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid var(--border);
}

.btn-icon {
    width: 36px;
    height: 36px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    border-radius: 4px;
    border: none;
    cursor: pointer;
}

.btn-remove {
    background: var(--danger);
    color: white;
    transition: var(--transition);
}

.btn-remove:hover {
    background: #dc2626;
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-success:hover {
    background: #059669;
}

@media print {
    .payment-controls {
        display: none !important;
    }

    .payment-container {
        font-size: 11px;
    }

    .payment-header {
        background: white;
        border-bottom: 2px solid var(--primary);
        padding: 10px;
        margin-bottom: 10px;
    }

    .payment-header h1 {
        font-size: 18pt;
        margin-bottom: 0;
    }

    .payment-header h2 {
        display: none;
    }

    .payment-section {
        padding: 8px;
        margin-bottom: 8px;
        background: white;
        border-left: 2px solid var(--primary);
    }

    .contract-box {
        padding: 8px;
        border: 1px solid var(--primary);
    }

    .contract-header,
    .grid-4,
    .contract-total {
        gap: 4px;
        font-size: 8px;
    }

    .grid-4 input,
    .grid-4 select,
    .amount-box input {
        font-size: 8px !important;
        padding: 3px 4px !important;
    }

    .amount-box span {
        padding: 3px 5px;
        font-size: 7px;
    }

    input,
    textarea,
    select {
        border: none !important;
        border-bottom: 1px solid var(--primary) !important;
        padding: 3px 4px !important;
        font-size: 9px !important;
    }

    @page {
        size: A4;
        margin: 8mm;
    }
}

@media print {
    body {
        background: white;
    }

    .header,
    .nav-tabs,
    .section-header button,
    .btn,
    .filters {
        display: none !important;
    }

    .main-content {
        padding: 0;
        background: white;
    }

    .expense-item,
    .company-card,
    .dashboard-section,
    .stat-card {
        box-shadow: none;
        border: 1px solid var(--border);
        page-break-inside: avoid;
    }
}
