body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f2f2f2;
}

header {
    background-color: #00796b;
    color: white;
    text-align: center;
    padding: 1rem 0;
}

main {
    padding: 20px;
    max-width: 1200px;
    margin: auto;
}

section {
    background-color: white;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

textarea#templateInput {
    width: 100%;
    height: 200px;
    font-family: monospace;
    font-size: 14px;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    resize: vertical;
}

form#dataForm {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

form#dataForm label {
    width: 100%;
    font-weight: bold;
}

form#dataForm input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.preview-box {
    padding: 20px;
    border: 1px dashed #aaa;
    background-color: #fcfcfc;
    white-space: pre-wrap;
}

.clanak {
    text-align: center;
    font-weight: bold;
    margin-top: 20px;
    margin-bottom: 10px;
}

.naslov {
    text-align: center;
    font-weight: bold;
    font-size: 20px;
    margin: 20px 0;
}

.signature-line {
    display: flex;
    justify-content: space-between;
    margin-top: 60px;
    font-weight: bold;
    padding: 0 20px;
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.actions button,
.editor button { /* Dodano za stilizaciju i editor sekcije (Generiraj polja) */
    padding: 10px 20px;
    background-color: #00796b;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s;
}

.actions button:hover,
.editor button:hover {
    background-color: #004d40;
}

@media print {
    body * {
        visibility: hidden;
    }
    #livePreview, #livePreview * {
        visibility: visible;
    }
    #livePreview {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        padding: 40px;
        background-color: white;
    }
}
