/* Invoice Management Pro - Public Styles */
/* Brand Colors: Primary #060644, Accent #bb133e */

:root {
    --imp-primary: #060644;
    --imp-primary-dark: #04043a;
    --imp-accent: #bb133e;
    --imp-accent-dark: #8b0e2e;
    --imp-success: #4caf50;
    --imp-warning: #f57c00;
}

.imp-invoice-container {
    max-width: 800px;
    margin: 40px auto;
    padding: 40px;
    background: white;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    font-family: 'Segoe UI', Arial, sans-serif;
}

.imp-invoice-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 3px solid var(--imp-primary);
}

.imp-company-info {
    flex: 1;
}

.imp-company-logo {
    max-width: 200px;
    max-height: 80px;
    margin-bottom: 15px;
}

.imp-company-info h1 {
    margin: 0 0 10px 0;
    font-size: 24px;
    color: var(--imp-primary);
}

.imp-company-info p {
    margin: 5px 0;
    color: #666;
    line-height: 1.5;
}

.imp-invoice-meta {
    text-align: right;
}

.imp-invoice-title {
    font-size: 36px;
    font-weight: bold;
    color: var(--imp-primary);
    margin: 0 0 10px 0;
}

.imp-invoice-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.imp-client-info,
.imp-invoice-info {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 5px;
    border-left: 4px solid var(--imp-accent);
}

.imp-client-info h3,
.imp-invoice-info h3 {
    margin: 0 0 15px 0;
    font-size: 14px;
    color: var(--imp-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.imp-client-info p,
.imp-invoice-info p {
    margin: 5px 0;
    color: #333;
}

.imp-items-table {
    width: 100%;
    border-collapse: collapse;
    margin: 40px 0;
}

.imp-items-table th {
    background: var(--imp-primary);
    color: white;
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

.imp-items-table td {
    padding: 12px;
    border-bottom: 1px solid #ddd;
}

.imp-items-table tr:last-child td {
    border-bottom: none;
}

.imp-text-right {
    text-align: right;
}

.imp-totals {
    margin-left: auto;
    width: 300px;
    margin-top: 20px;
}

.imp-totals-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.imp-totals-row.imp-total {
    border-top: 2px solid var(--imp-primary);
    border-bottom: 2px solid var(--imp-primary);
    font-weight: bold;
    font-size: 18px;
    margin-top: 10px;
    color: var(--imp-accent);
}

.imp-notes {
    margin-top: 40px;
    padding: 20px;
    background: #f9f9f9;
    border-left: 4px solid var(--imp-accent);
}

.imp-notes h3 {
    margin: 0 0 10px 0;
    font-size: 16px;
    color: var(--imp-primary);
}

.imp-payment-section {
    margin-top: 40px;
    padding: 30px;
    background: #f0f4ff;
    border: 2px solid var(--imp-primary);
    border-radius: 5px;
    text-align: center;
}

.imp-payment-section h3 {
    margin: 0 0 10px 0;
    color: var(--imp-primary);
}

.imp-payment-section .amount-due {
    font-size: 28px;
    font-weight: bold;
    color: var(--imp-accent);
    margin-bottom: 20px;
}

.imp-payment-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.imp-payment-button {
    display: inline-block;
    padding: 15px 30px;
    background: var(--imp-primary);
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    transition: background 0.3s;
}

.imp-payment-button:hover {
    background: var(--imp-primary-dark);
    color: white;
}

.imp-payment-button.paypal {
    background: #ffc439;
    color: #003087;
}

.imp-payment-button.paypal:hover {
    background: #f0b429;
}

.imp-payment-button.stripe {
    background: #635bff;
}

.imp-payment-button.stripe:hover {
    background: #4f47cc;
}

.imp-status-badge {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 14px;
    margin-top: 10px;
}

.imp-status-paid {
    background: var(--imp-success);
    color: white;
}

.imp-status-sent,
.imp-status-pending {
    background: var(--imp-primary);
    color: white;
}

.imp-status-overdue {
    background: var(--imp-accent);
    color: white;
}

.imp-status-draft {
    background: #999;
    color: white;
}

.imp-actions {
    margin-top: 30px;
    text-align: center;
}

.imp-action-button {
    margin: 0 10px;
    padding: 10px 20px;
    background: var(--imp-primary);
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
}

.imp-action-button:hover {
    background: var(--imp-primary-dark);
    color: white;
}

/* Payment Success Message */
.imp-payment-success {
    background: #e8f5e9;
    border: 2px solid var(--imp-success);
    padding: 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    text-align: center;
}

.imp-payment-success h3 {
    color: var(--imp-success);
    margin: 0 0 10px 0;
}

/* Print styles */
@media print {
    .imp-payment-section,
    .imp-actions {
        display: none;
    }
    
    .imp-invoice-container {
        box-shadow: none;
        padding: 20px;
    }
}

/* Responsive */
@media screen and (max-width: 768px) {
    .imp-invoice-container {
        padding: 20px;
        margin: 20px;
    }
    
    .imp-invoice-header {
        flex-direction: column;
    }
    
    .imp-invoice-meta {
        text-align: left;
        margin-top: 20px;
    }
    
    .imp-invoice-details {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .imp-items-table {
        font-size: 12px;
    }
    
    .imp-items-table th,
    .imp-items-table td {
        padding: 8px 4px;
    }
    
    .imp-payment-buttons {
        flex-direction: column;
    }
    
    .imp-payment-button {
        width: 100%;
    }
}
