body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 20px;
    background-color: #f4f4f4;
    color: #333;
    direction: rtl; /* For Arabic layout */
}

.container {
    max-width: 600px;
    margin: auto;
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

h1, h2 {
    text-align: center;
    color: #333;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.form-group input[type="text"],
.form-group select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box; /* Important for width calculation */
}

button {
    display: block;
    width: 100%;
    padding: 10px;
    background-color: #5cb85c;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    margin-top: 10px;
}

button:hover {
    background-color: #4cae4c;
}

#downloadBtn {
    background-color: #007bff;
    margin-top: 5px; /* Add some space */
}

#downloadBtn:hover {
    background-color: #0056b3;
}


.output-area {
    margin-top: 20px;
    text-align: center;
}

#outputContainer {
    margin-top: 10px;
    padding: 10px;
    border: 1px dashed #ccc;
    min-height: 100px; /* So it's visible even when empty */
    display: flex; /* For centering content */
    justify-content: center; /* For centering content */
    align-items: center; /* For centering content */
}

/* JsBarcode يولد SVG, QRious يولد Canvas أو img. هذا لـ canvas */
#outputContainer canvas,
#outputContainer img {
    max-width: 100%;
    height: auto;
}

.error-message {
    color: red;
    margin-top: 10px;
    font-weight: bold;
}