/* General Styles */
body {
    font-family: 'Arial', sans-serif;
    background-color: #f8f9fa;
}

h1, h2, h3, h4, h5, h6 {
    color: #0d6efd;
}

/* Custom Title Styling */
h1.report-title-custom {
    color: #FF5722 !important; /* Safety Orange */
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.report-title-custom .fa-wrench {
    margin-left: 10px;
    animation: wrench-wiggle 2s ease-in-out infinite;
}

@keyframes wrench-wiggle {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-20deg); }
    75% { transform: rotate(20deg); }
}

.card {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

/* Test Type Button Styles */
.test-type-btn {
    min-height: 80px;
    font-size: 1.1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border-width: 2px;
}

.test-type-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.test-type-btn.active {
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: white;
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.4);
}

.test-type-btn.active:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
    transform: translateY(-2px);
}

/* Duration Button Styles */
.duration-btn {
    min-width: 50px;
}

.duration-btn.active {
    background-color: #6c757d;
    border-color: #6c757d;
    color: white;
}

/* Date Button Styles */
.date-btn {
    min-width: 90px;
}

.date-btn.active {
    background-color: #6c757d;
    border-color: #6c757d;
    color: white;
}

/* Test Result Button Styles */
.test-result-btn {
    min-height: 80px;
    font-size: 1.1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border-width: 2px;
}

.test-result-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.test-result-btn.active.btn-success {
    box-shadow: 0 4px 12px rgba(25, 135, 84, 0.4);
}

.test-result-btn.active.btn-danger {
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.4);
}

.test-result-btn small {
    font-size: 0.85rem;
    opacity: 0.9;
}

/* Supply/Sewer Button Styles */
.supply-sewer-btn {
    min-height: 80px;
    font-size: 1.1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border-width: 2px;
    border-color: #ff9800;
    color: #ff9800;
}

.supply-sewer-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(255, 152, 0, 0.3);
    background-color: #fff3e0;
    border-color: #ff9800;
    color: #ff9800;
}

.supply-sewer-btn.active {
    background-color: #ff9800;
    border-color: #ff9800;
    color: white;
    box-shadow: 0 4px 12px rgba(255, 152, 0, 0.4);
}

.supply-sewer-btn.active:hover {
    background-color: #f57c00;
    border-color: #f57c00;
    transform: translateY(-2px);
}

/* Gas Test Styles */
.gas-test-pressure-locked {
    background-color: #e9ecef !important;
}

.gas-test-reset-active {
    background-color: #FF9800 !important;
    border-color: #FF9800 !important;
    color: white !important;
}

.gas-test-reset-active:hover {
    background-color: #F57C00 !important;
    border-color: #F57C00 !important;
    color: white !important;
}

.gas-test-header-title {
    color: #FF9800 !important;
    font-weight: bold;
}

.gas-test-pressure-field {
    min-width: 0;
}

.gas-test-fixture-row {
    display: flex;
    flex-wrap: wrap;
}

.gas-test-fixture-row .gas-test-fixture-name,
.gas-test-fixture-row .gas-test-btu-input {
    min-width: 0;
}

/* Signature Pad Styles */
.signature-pad {
    width: 100%;
    height: 150px;
    background-color: #fff;
}

/* Report Styles */
.report-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    font-family: Arial, sans-serif;
    color: #212529; /* Bootstrap dark text color */
}

.report-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 1px solid #adb5bd;
    padding-bottom: 20px;
}

.company-logo {
    flex: 0 0 auto;
}

.report-title {
    text-align: right;
}

.report-title h2 {
    color: #0d6efd;
    margin: 0;
    font-size: 24px;
}

.report-date {
    color: #495057;
    margin: 5px 0 0 0;
    text-align: right;
}

.report-section {
    margin-bottom: 25px;
}

.report-sections-row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 25px;
}

.half-width {
    flex: 1 1 calc(50% - 10px);
    min-width: 300px;
    margin-bottom: 0;
}

.report-section h3 {
    color: #0d6efd;
    margin-bottom: 15px;
    font-size: 18px;
    font-weight: bold;
}

.report-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

.report-field {
    margin-bottom: 10px;
}

.report-field label {
    font-weight: bold;
    display: inline-block;
    margin-right: 5px;
    min-width: 80px;
}

.report-field.full-width {
    grid-column: span 2;
}

.report-address {
    margin-bottom: 15px;
}

.report-signatures {
    display: flex;
    justify-content: space-between;
    margin-top: 15px;
}

.signature-block {
    width: 45%;
}

.signature-image {
    height: 100px;
    border-bottom: 1px solid #000;
    margin-bottom: 5px;
}

.signature-image img {
    max-width: 100%;
    max-height: 100%;
}

.signature-name {
    text-align: center;
}

.report-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
    font-size: 10px;
    color: #6c757d;
}

.qr-code {
    width: 100px;
    height: 100px;
}

.report-verification {
    text-align: right;
}

/* Invoice Styles */
.invoice-container {
    background-color: white;
    padding: 20px;
    max-width: 800px;
    margin: 0 auto;
    font-size: 12px;
    line-height: 1.5;
    font-family: 'Arial', sans-serif;
}

.invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #0d6efd;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.invoice-title {
    text-align: right;
}

.invoice-title h2 {
    margin-bottom: 5px;
    color: #0d6efd;
    font-size: 24px;
    font-weight: bold;
}

.invoice-addresses {
    display: flex;
    justify-content: space-between;
    margin-bottom: 30px;
}

.from-address, .to-address {
    width: 45%;
}

.invoice-items {
    margin-bottom: 30px;
}

.invoice-table {
    width: 100%;
    border-collapse: collapse;
}

.invoice-table th, .invoice-table td {
    border: 1px solid #dee2e6;
    padding: 8px 12px;
    text-align: left;
}

.invoice-table th {
    white-space: nowrap;
}

.invoice-table th:nth-child(3) {
    min-width: 90px;
}

.invoice-table th {
    background-color: #f8f9fa;
    font-weight: bold;
}

.invoice-table tfoot td {
    font-weight: bold;
    background-color: #f8f9fa;
}

.invoice-test-details {
    margin-bottom: 30px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 5px;
}

.invoice-test-detail-row {
    display: flex;
    margin-bottom: 8px;
}

.invoice-test-label {
    font-weight: bold;
    margin-right: 10px;
    min-width: 100px;
}

.invoice-notes {
    margin-bottom: 30px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 5px;
}

.invoice-certification {
    margin-bottom: 30px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 5px;
}

.invoice-certification h4 {
    margin-bottom: 10px;
}

.invoice-certification p {
    margin: 0;
    line-height: 1.6;
}

.invoice-footer {
    text-align: center;
    font-size: 10px;
    color: #6c757d;
    margin-top: 30px;
    border-top: 1px solid #dee2e6;
    padding-top: 15px;
}

/* Print Styles */
@media print {
    body {
        background-color: white;
    }
    
    .container {
        width: 100%;
        max-width: 100%;
        padding: 0;
        margin: 0;
    }
    
    .report-container, .invoice-container {
        padding: 0;
    }
    
    .no-print {
        display: none !important;
    }
}
