/* --- Hemang Invoice Generator - Colorful Theme v1.7.7 --- */
#invoice-generator-wrapper { max-width: 100%; margin: 40px auto; padding: 20px 20px 40px 40px; background: #f8f9fa; border: none; border-radius: 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif; }
#invoice-generator-wrapper h2 { text-align: center; color: #333; font-size: 2.2em; font-weight: 700; letter-spacing: -1px; border-bottom: none; padding-bottom: 0; margin-bottom: 40px; }
#invoice-generator-wrapper h3 { font-size: 1.4em; padding-bottom: 10px; margin-bottom: 25px; border-bottom: 2px solid; border-left: 6px solid; padding-left: 15px; border-radius: 4px 0 0 0; }
.fig-section { margin-bottom: 25px; padding: 25px; border: 1px solid #e9ecef; border-radius: 8px; background: #ffffff; box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05); }
.fig-split { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.fig-col { width: 100%; min-width: 300px; flex: 1; }
.fig-row { margin-bottom: 15px; }
.fig-row label { display: block; font-weight: 600; color: #495057; margin-bottom: 6px; font-size: 0.95em; }
.fig-row input[type="text"], .fig-row input[type="email"], .fig-row input[type="date"], .fig-row textarea, .fig-row select { width: 100%; padding: 12px; border: 1px solid #ced4da; border-radius: 6px; box-sizing: border-box; font-size: 1em; transition: all 0.2s ease-in-out; }
.fig-row textarea { height: 100px; resize: vertical; }
.fig-row input:focus, .fig-row textarea:focus, .fig-row select:focus { border-color: var(--primary-color, #3498db); box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2); outline: none; }
#invoice-generator-wrapper h3 { --primary-color: currentColor; }
.fig-row input:focus, .fig-row textarea:focus, .fig-row select:focus { box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary-color) 25%, transparent); }
#invoice-items { width: 100%; border-collapse: collapse; margin-bottom: 15px; }
#invoice-items th, #invoice-items td { border: 1px solid #e9ecef; padding: 12px; text-align: left; }
#invoice-items th { background-color: #f8f9fa; font-weight: 600; }
#invoice-items input { width: 100%; border: 1px solid #ced4da; padding: 8px; border-radius: 4px; }
#invoice-items .item-total { font-weight: 700; color: #343a40; }
.remove-item-btn { background: #e74c3c; color: white; border: none; border-radius: 50%; cursor: pointer; width: 30px; height: 30px; line-height: 30px; text-align: center; font-weight: bold; transition: background 0.2s; }
.remove-item-btn:hover { background: #c0392b; }
#add-item-btn { background-color: #2ecc71; color: white; font-weight: 600; border: none; border-radius: 6px; padding: 10px 20px; transition: background-color 0.2s; }
#add-item-btn:hover { background-color: #27ae60; }
.submit-section { text-align: right; margin-top: 20px; padding: 0; border: none; background: none; box-shadow: none; }
.button.button-primary { font-size: 1.3em; font-weight: bold; padding: 12px 30px; height: auto; border-radius: 8px; color: white; border: none; text-shadow: 0 1px 1px rgba(0,0,0,0.2); box-shadow: 0 2px 5px rgba(0,0,0,0.2); transition: all 0.2s ease-in-out; }
.button.button-primary:hover { transform: translateY(-2px); box-shadow: 0 4px 10px rgba(0,0,0,0.2); }

/* --- NEW FOOTER LAYOUT --- */
.fig-footer-section { display: flex; gap: 30px; align-items: flex-start; flex-wrap: wrap; }
.fig-col-left { flex: 2; min-width: 300px; }
.fig-col-right { flex: 1; min-width: 300px; }
.fig-footer-section .fig-section { margin-bottom: 0; }
.fig-col-left .fig-section { margin-bottom: 25px; }

/* Totals Section */
.totals-section { padding: 20px; }
.totals-row { display: flex; justify-content: space-between; padding: 6px 0; align-items: center; font-size: 1.05em; }
.totals-row.roundoff-row { color: #6c757d; font-style: italic; }
.totals-row label { font-weight: 600; }
.totals-row.total { font-weight: bold; font-size: 1.4em; border-top: 2px solid #343a40; margin-top: 10px; padding-top: 12px; }
#tax_rate, #shipping_charge { width: 120px; text-align: right; padding: 8px; border: 1px solid #ced4da; border-radius: 4px; font-size: 1em; }
.discount-row .discount-input-group { display: flex; width: 120px; }
.discount-row input { width: 70%; border-radius: 4px 0 0 4px; border-right: none; }
.discount-row select { width: 30%; border-radius: 0 4px 4px 0; padding: 8px 4px; background-color: #f1f3f5; border: 1px solid #ced4da; }
.discount-total-row { font-style: italic; color: #e74c3c; }
.tax-amount-row { font-style: italic; color: #555; }
#amount_in_words_text { font-weight: bold; color: #343a40; font-style: italic; font-size: 1.1em; }
.fig-admin-alert { background: #ffebe5; border: 1px solid #c00; padding: 15px; margin-bottom: 20px; border-radius: 4px; }