/* File: public/assets/css/kia-mobile.css */

/* --- Tampilan Dasar (Desktop/Laptop) --- */
.card-custom {
    padding: 30px;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    background-color: white;
    max-width: 800px;
    margin: 0 auto; /* Tengah di desktop */
}

.option-group {
    border: 1px solid #dee2e6;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 12px;
    transition: all 0.2s;
    cursor: pointer;
    background: #fff;
}

/* Efek Hover di Desktop */
.option-group:hover {
    border-color: #6f42c1;
    background-color: #fcfbff;
    transform: translateY(-2px);
}

.option-group.active {
    border-color: #6f42c1;
    background-color: #f3effa;
    border-width: 2px;
    box-shadow: 0 4px 10px rgba(111, 66, 193, 0.15);
}

/* --- LOGIKA DINAMIS (Tablet & Smartphone) --- */
@media (max-width: 768px) {
    .container {
        padding-left: 10px;
        padding-right: 10px;
    }

    /* Card memenuhi layar HP agar tidak sempit */
    .card-custom {
        padding: 15px;
        border: none;
        box-shadow: none;
        background: transparent;
        margin-top: 0;
    }
    
    /* Tombol pilihan diperbesar agar mudah disentuh jari (Touch Friendly) */
    .option-group {
        padding: 15px;
        margin-bottom: 15px;
        /* Biar tidak loncat saat disentuh di HP */
        transform: none !important; 
        box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    }

    /* Font judul lebih kecil dikit biar muat */
    h4 {
        font-size: 1.25rem;
        font-weight: bold;
    }

    /* Tombol navigasi (Kembali/Lanjut) jadi full width & bertumpuk */
    .btn-nav-group {
        display: flex;
        flex-direction: column-reverse; /* Tombol Lanjut di atas, Kembali di bawah */
        gap: 10px;
    }

    .btn-nav-group .btn {
        width: 100%; /* Full lebar layar */
        padding: 12px; /* Lebih tebal biar enak dipencet */
        font-size: 1rem;
    }

    /* Responsive Table untuk Lampiran */
    .lampiran-table {
        display: block;
        overflow-x: auto;
    }

    .lampiran-table thead {
        display: none;
    }

    .lampiran-table tbody tr {
        display: block;
        margin-bottom: 15px;
        border: 1px solid #dee2e6;
        border-radius: 8px;
        padding: 10px;
        background: white;
    }

    .lampiran-table tbody td {
        display: block;
        text-align: left;
        padding: 8px 0;
        border: none;
        font-size: 0.9rem;
    }

    .lampiran-table tbody td:before {
        content: attr(data-label);
        font-weight: bold;
        display: block;
        margin-bottom: 5px;
        color: #495057;
        font-size: 0.85rem;
    }

    /* Data Row Responsive */
    .data-row {
        flex-direction: column;
        margin-bottom: 8px;
    }

    .data-label {
        width: 100%;
        margin-bottom: 2px;
        font-size: 0.85rem;
    }

    .data-value {
        font-size: 0.9rem;
    }

    /* Tombol aksi di mobile */
    .lampiran-table .d-flex {
        flex-wrap: wrap;
        gap: 5px;
        justify-content: center;
    }

    .lampiran-table .btn {
        font-size: 0.75rem;
        padding: 4px 8px;
        min-width: 70px;
    }

    /* Box proses responsif */
    .box-proses {
        padding: 15px;
        margin-bottom: 20px;
    }

    .box-proses .row {
        flex-direction: column;
    }

    .box-proses .col-md-9 {
        order: 2;
    }

    .box-proses .col-md-3 {
        order: 1;
        text-align: center;
        margin-bottom: 15px;
    }

    /* Modal responsif */
    .modal-dialog {
        margin: 10px;
        max-width: calc(100% - 20px);
    }

    /* Alert responsif */
    .alert-permohonan {
        font-size: 0.8rem;
        padding: 8px;
        margin-top: 10px;
    }
}

/* --- Tampilan Tablet (768px - 1024px) --- */
@media (min-width: 769px) and (max-width: 1024px) {
    .container {
        max-width: 95%;
    }
    
    .card-custom {
        padding: 20px;
        max-width: 95%;
    }

    .lampiran-table th,
    .lampiran-table td {
        font-size: 0.8rem;
        padding: 0.4rem;
    }

    .btn {
        font-size: 0.8rem;
        padding: 5px 10px;
    }
}