/* Import Font */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap');

/* Reset dan Pengaturan Dasar */
body {
    font-family: 'Poppins', sans-serif;
    background-color: #F4F7FC;
    color: #333;
    line-height: 1.6;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 2rem 0;
    margin: 0;
}

.invoice-container {
    background-color: #FFFFFF;
    width: 100%;
    max-width: 800px;
    margin: 20px;
    padding: 2.5rem 3rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border-top: 5px solid #4A90E2;
    /* Aksen warna modern */
    font-size: 11.9px;
}

/* Header */
.invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid #E8E8E8;
}

.company-name {
    font-size: 1.8rem;
    font-weight: 600;
    color: #4A90E2;
    margin: 0;
}

.company-address {
    font-size: 0.9rem;
    color: #666;
    margin-top: 5px;
}

.invoice-title h2 {
    font-size: 2.5rem;
    font-weight: 300;
    text-align: right;
    color: #888;
    margin: 0;
}

.invoice-number {
    font-size: 1rem;
    text-align: right;
    color: #555;
    margin-top: 5px;
}

/* Detail Invoice */
.invoice-details {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2.5rem;
}

.section-title {
    font-size: 0.8rem;
    font-weight: 500;
    color: #888;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.client-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
    margin: 0;
}

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

.meta-item {
    margin-bottom: 0.5rem;
}

.meta-label {
    font-weight: 500;
    color: #555;
    margin: 0;
    display: inline-block;
    width: 130px;
}

.meta-value {
    color: #333;
    margin: 0;
    display: inline-block;
}

/* Tabel Item */
.items-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
}

.items-table thead {
    background-color: #F9F9F9;
    border-bottom: 2px solid #E8E8E8;
}

.items-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: #444;
    font-size: 0.9rem;
    width: 0px;
}

.items-table td {
    padding: 0rem 0rem 0.1rem 0rem;
    border-bottom: 1px solid #DDDDDD;
    border: 1px solid #D1CDCD;
    text-align: left;
}

.items-table tbody tr:last-child td {
    border-bottom: 0px none;
}

/* Footer */
.invoice-footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding-top: 0rem;
    border-top: 3px solid #E8E8E8;
}

.notes-section {
    flex: 1;
    font-size: 0.85rem;
    color: #666;
    padding-right: 2rem;
}

.total-section {
    width: 40%;
    max-width: 280px;
}

.total-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.total-label {
    font-weight: 500;
    color: #555;
}

.grand-total {
    margin-top: 1rem;
    padding-top: 0.8rem;
    border-top: 2px solid #4A90E2;
}

.grand-total .total-label, .grand-total .total-value {
    font-weight: 600;
    font-size: 1.2rem;
    color: #4A90E2;
}

.payment-info {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px dashed #CCC;
    font-size: 0.9rem;
    color: #555;
}

/* Desain Responsif */
@media (max-width: 768px) {
    .invoice-container {
        padding: 2rem 1.5rem;
    }
    
    .invoice-header, .invoice-details, .invoice-footer {
        flex-direction: column;
    }
    
    .invoice-title, .invoice-meta {
        text-align: left;
        margin-top: 1.5rem;
    }
    
    .invoice-meta .meta-label {
        width: auto;
        margin-right: 10px;
    }
    
    .invoice-footer {
        align-items: stretch;
    }
    
    .notes-section {
        margin-bottom: 2rem;
        padding-right: 0;
    }
    
    .total-section {
        width: 100%;
        max-width: none;
    }
}
