body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f7f6;
    color: #333;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.container {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    width: 80%;
    max-width: 900px;
    margin: 20px;
}

h1, h2 {
    color: #2c3e50;
    margin-top: 0;
}

p {
    color: #777;
}

nav {
    margin-bottom: 20px;
}

nav a {
    color: #3498db;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 5px;
    background-color: #ecf0f1;
}

nav a:hover {
    background-color: #d5dbdb;
}

#invoice-form, #invoice-preview {
    margin-top: 20px;
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #555;
    font-weight: bold;
}

.form-group input[type="text"],
.form-group input[type="date"],
.form-group input[type="email"],
.form-group input[type="number"],
.form-group input[type="tel"],
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    box-sizing: border-box;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

button[type="submit"],
button#addItem,
button#download-invoice {
    background-color: #3498db;
    color: #fff;
    padding: 12px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s ease;
}

button[type="submit"]:hover,
button#addItem:hover,
button#download-invoice:hover {
    background-color: #2980b9;
}

#items-container .item {
    border: 1px solid #ddd;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 15px;
    background-color: #f9f9f9;
}

#items-container .item .form-group {
    margin-bottom: 10px;
}

#invoice-preview #invoice {
    border: 1px solid #ddd;
    padding: 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    background-color: #fff;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.05);
}

/* Invoice Styling - improve appearance when printed or downloaded */
#invoice {
    font-family: 'Arial', sans-serif;
    color: #333;
    max-width: 800px;
    margin: auto;
    padding: 30px;
    border: 1px solid #ccc;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

#invoice h1 {
    font-size: 2.5em;
    color: #3498db;
    margin-bottom: 20px;
    text-align: center;
}

#invoice h2 {
    font-size: 1.8em;
    color: #2c3e50;
    margin-top: 25px;
    margin-bottom: 15px;
    border-bottom: 2px solid #eee;
    padding-bottom: 5px;
}

#invoice h3 {
    font-size: 1.4em;
    color: #555;
    margin-top: 20px;
    margin-bottom: 10px;
}

#invoice p, #invoice address {
    font-size: 1em;
    color: #666;
    line-height: 1.6;
}

#invoice address {
    margin-bottom: 20px;
}

#invoice table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

#invoice th, #invoice td {
    padding: 10px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

#invoice th {
    background-color: #f8f8f8;
    color: #555;
    font-weight: bold;
}

#invoice tfoot {
    margin-top: 20px;
    font-weight: bold;
}

#invoice .invoice-notes {
    margin-top: 30px;
    padding: 15px;
    border: 1px dashed #ddd;
    border-radius: 5px;
    background-color: #f9f9f9;
}

#invoice .invoice-notes p {
    font-style: italic;
    color: #777;
}