* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    background-color: #f8f9fa;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

h1 {
    text-align: center;
    color: #2c3e50;
    margin-bottom: 30px;
}

h2 {
    color: #34495e;
    margin-bottom: 20px;
}

.form-container {
    background-color: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.form-group {
    margin-bottom: 15px;
}

label {
    display: block;
    margin-bottom: 5px;
    color: #555;
}

input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.btn-submit {
    background-color: #3498db;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    width: 100%;
}

.btn-submit:hover {
    background-color: #2980b9;
}

.receipts-container {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.receipt-card {
    background-color: #f9f9f9;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 4px;
    border: 1px solid #eee;
}

.receipt-card h3 {
    color: #2c3e50;
    margin-bottom: 10px;
}

.receipt-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
}

.receipt-detail {
    margin-bottom: 5px;
}

.receipt-actions {
    margin-top: 10px;
    display: flex;
    gap: 10px;
}

.btn-download {
    background-color: #27ae60;
    color: white;
    padding: 5px 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.btn-download:hover {
    background-color: #219a52;
}

.card {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border: none;
}

.card-title {
    color: #2c3e50;
    font-weight: 600;
}

.table {
    margin-bottom: 0;
}

.table th {
    background-color: #f8f9fa;
    font-weight: 600;
    border-bottom: 2px solid #dee2e6;
}

.table td {
    vertical-align: middle;
}

.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 1rem;
}

/* Make action buttons more compact */
.btn-group-sm > .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* Optimize table cell padding */
.table > :not(caption) > * > * {
    padding: 0.5rem;
}

/* Make checkbox column narrow */
.select-checkbox {
    width: 30px;
    padding-left: 8px !important;
    padding-right: 8px !important;
}

/* Ensure consistent column widths */
.table th {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Make serial number column compact */
.table td:nth-child(2) {
    text-align: center;
}

/* Style amounts to be right-aligned */
.table td:nth-child(6),
.table td:nth-child(7) {
    text-align: right;
}

/* Ensure action buttons stay on one line */
.btn-group {
    flex-wrap: nowrap;
}

/* Add subtle hover effect on rows */
.table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

.form-control:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25);
}

.btn-primary {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

.btn-primary:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
}

.btn-info {
    color: #fff;
}

.alert {
    margin-bottom: 1rem;
    border: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.modal-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}

.modal-body dl {
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .card {
        margin-bottom: 15px;
    }
}
