:root { --primary-color: #4361ee; --secondary-color: #3f37c9; --accent-color: #4cc9f0; --light-color: #f8f9fa; --dark-color: #212529; --success-color: #4bb543; --warning-color: #ff9500; --danger-color: #ff3b30; } * { box-sizing: border-box; margin: 0; padding: 0; } body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; line-height: 1.6; color: var(--dark-color); background-color: #f0f2f5; padding: 20px; } .container { max-width: 1000px; margin: 0 auto; background-color: white; padding: 30px; border-radius: 12px; box-shadow: 0 5px 15px rgba(0,0,0,0.1); } h1, h2, h3 { color: var(--primary-color); } h1 { text-align: center; margin-bottom: 30px; font-size: 2.2rem; position: relative; padding-bottom: 15px; } h1::after { content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); width: 100px; height: 4px; background: linear-gradient(90deg, var(--primary-color), var(--accent-color)); border-radius: 2px; } .input-section, .preview-section { margin-bottom: 30px; padding: 25px; border-radius: 10px; background-color: white; box-shadow: 0 2px 10px rgba(0,0,0,0.05); } .form-group { margin-bottom: 20px; } label { display: block; margin-bottom: 8px; font-weight: 600; color: var(--secondary-color); } input, select, textarea { width: 100%; padding: 12px; border: 1px solid #ddd; border-radius: 6px; font-size: 16px; transition: border 0.3s; } input:focus, select:focus, textarea:focus { border-color: var(--accent-color); outline: none; box-shadow: 0 0 0 3px rgba(76, 201, 240, 0.2); } button { padding: 12px 20px; border: none; border-radius: 6px; cursor: pointer; font-size: 16px; font-weight: 600; transition: all 0.3s; display: inline-flex; align-items: center; justify-content: center; gap: 8px; } button:hover { transform: translateY(-2px); box-shadow: 0 4px 8px rgba(0,0,0,0.1); } table { width: 100%; border-collapse: collapse; margin-top: 20px; box-shadow: 0 1px 3px rgba(0,0,0,0.1); } th, td { padding: 12px 15px; text-align: left; border-bottom: 1px solid #e0e0e0; } th { background-color: var(--primary-color); color: white; font-weight: 600; } tr:nth-child(even) { background-color: #f9f9f9; } tr:hover { background-color: #f1f1f1; } .logo-container { display: flex; align-items: center; gap: 15px; margin-bottom: 20px; } .logo-preview { width: 80px; height: 80px; object-fit: contain; border: 1px dashed #ccc; border-radius: 8px; padding: 5px; } .bill-preview { background-color: white; padding: 25px; border-radius: 10px; box-shadow: 0 2px 10px rgba(0,0,0,0.05); margin-top: 20px; } .bill-header { display: flex; flex-wrap: wrap; justify-content: space-between; margin-bottom: 30px; gap: 20px; } .company-info { flex: 1; min-width: 250px; } .bill-info { text-align: right; } .bill-title { font-size: 28px; font-weight: bold; margin-bottom: 10px; color: var(--primary-color); } .bill-details { margin-bottom: 30px; } .bill-footer { margin-top: 50px; text-align: center; font-style: italic; color: #666; padding-top: 20px; border-top: 1px solid #eee; } .total-row { font-weight: bold; background-color: #f5f7ff; } .total-row td { border-top: 2px solid var(--primary-color); border-bottom: 2px solid var(--primary-color); } .action-buttons { display: flex; gap: 15px; margin-top: 25px; flex-wrap: wrap; } #addItem { background-color: var(--primary-color); color: white; } #addItem:hover { background-color: var(--secondary-color); } #clearAll { background-color: var(--danger-color); color: white; } #clearAll:hover { background-color: #e0352b; } #generateBill { background-color: var(--success-color); color: white; width: 100%; } #generateBill:hover { background-color: #3fa238; } #downloadBill { background: linear-gradient(135deg, var(--primary-color), var(--accent-color)); color: white; } #downloadBill:hover { background: linear-gradient(135deg, var(--secondary-color), #3ac2f0); } #printBill { background-color: var(--warning-color); color: white; } #printBill:hover { background-color: #e68a00; } .remove-item { background-color: transparent; color: var(--danger-color); padding: 5px; font-size: 18px; border-radius: 50%; width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; } .remove-item:hover { background-color: rgba(255, 59, 48, 0.1); transform: none; box-shadow: none; } .logo-svg { width: 80px; height: 80px; } #pdfContent { position: absolute; left: -9999px; width: 794px; /* A4 width in pixels at 96dpi */ padding: 20px; background: white; } /* Responsive styles */ @media (max-width: 768px) { .container { padding: 15px; } .input-section, .preview-section { padding: 15px; } h1 { font-size: 1.8rem; } .bill-header { flex-direction: column; } .bill-info { text-align: left; } th, td { padding: 8px 10px; font-size: 14px; } .action-buttons button { flex: 1; min-width: 120px; } } @media (max-width: 480px) { body { padding: 10px; } .container { padding: 10px; } h1 { font-size: 1.5rem; } input, select, textarea, button { padding: 10px; } .action-buttons { gap: 10px; } .action-buttons button { font-size: 14px; } }