/* Palet Warna Ungu
   - #5D3FD3: Ungu utama, kuat
   - #8A6BDE: Ungu medium, untuk tombol
   - #EAE3F7: Ungu muda, untuk latar belakang
   - #3D2991: Ungu gelap, untuk teks
*/

/* Styling untuk halaman utama */
body {
    font-family: 'Poppins', sans-serif;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: #EAE3F7; /* Latar belakang ungu muda */
    margin: 20px;
    color: #3D2991; /* Teks ungu gelap */
}

.container {
    background-color: #fff;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    text-align: center;
    width: 95%;
    max-width: 1000px;
}

h1 {
    color: #5D3FD3; /* Ungu utama */
    font-weight: 600;
}

/* Styling untuk form input */
.card-options {
    margin-bottom: 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    align-items: center;
    padding: 15px;
    background-color: #f7f3ff; /* Latar belakang ungu lebih terang */
    border-radius: 8px;
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.05);
}

.option-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
    text-align: left;
}

.option-group label {
    font-weight: 600;
    font-size: 14px;
}

.option-group select, 
.option-group input[type="file"] {
    padding: 8px;
    border-radius: 6px;
    border: 1px solid #C4B9E4; /* Ungu keabu-abuan untuk border */
    min-width: 200px;
    color: #3D2991;
    background-color: #fff;
}

.option-group input[type="checkbox"] {
    margin-right: 5px;
    accent-color: #8A6BDE; /* Warna ungu untuk checkbox */
}

button {
    padding: 10px 25px;
    font-size: 16px;
    cursor: pointer;
    background-color: #8A6BDE; /* Ungu medium untuk tombol */
    color: white;
    font-weight: 600;
    border: none;
    border-radius: 5px;
    margin-top: 20px;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: #5D3FD3; /* Ungu utama saat di-hover */
}

/* --- Area Cetak dan Kartu --- */

#print-area {
    width: 210mm;
    height: 297mm;
    border: 2px dashed #C4B9E4; /* Border ungu untuk area cetak */
    padding: 2mm 4mm;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 4mm;
    margin: 20px auto;
    overflow: hidden;
    background-color: #fcfbff;
}

#left-column, #right-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3mm;
}

.card {
    width: 87mm;
    height: 57mm;
    border: none;
    box-sizing: border-box;
    padding: 0;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.3s;
    background-color: #EAE3F7; /* Latar belakang kartu ungu muda */
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.card img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

/* Style untuk mode mirror */
.card.mirror {
    transform: scaleX(-1);
}

/* --- Pengaturan Cetak --- */

@media print {
    /* Menghilangkan margin bawaan browser */
    @page {
        margin: 0;
    }
    
    body * {
        visibility: hidden;
    }
    
    #print-area, #print-area * {
        visibility: visible;
    }
    
    #print-area {
        position: absolute;
        left: 0;
        top: 0;
        height: 297mm;
        margin: 0;
        border: none;
        justify-content: flex-start;
        align-items: flex-start;
        padding: 2mm 20mm 0 20mm;
        gap: 10mm;
    }

    #left-column, #right-column {
        gap: 3mm;
    }

    .card {
        background-color: transparent;
        box-shadow: none;
    }
}