/* CSS untuk Modul Attitude */

.prodi-badge {
    padding: 5px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    display: inline-block;
}

.prodi-badge.status-pending {
    background-color: #fef08a; /* Kuning Pucat */
    color: #854d0e;
    border: 1px solid #fde047;
}

.prodi-badge.status-selesai {
    background-color: #dcfce7; /* Hijau Pucat */
    color: #166534;
    border: 1px solid #bbf7d0;
}

.btn-detail-attitude {
    background-color: #f1f5f9;
    color: #475569;
    border: 1px solid #cbd5e1;
    transition: all 0.2s;
}

.btn-detail-attitude:hover {
    background-color: #e2e8f0;
    color: #0f172a;
}

.btn-selesai-attitude {
    background-color: #10b981 !important;
    border-color: #059669 !important;
}

.btn-selesai-attitude:hover {
    background-color: #059669 !important;
}

/* Modal Overlay Override */
.prodi-modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(15, 23, 42, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;
}

.prodi-modal-content {
    background: white;
    padding: 25px;
    border-radius: 12px;
    width: 90%;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 15px;
    margin-bottom: 15px;
}

.modal-header h3 { margin: 0; font-size: 18px; color: #1e293b; }
.modal-close-icon { cursor: pointer; font-size: 24px; color: #94a3b8; }
.modal-close-icon:hover { color: #ef4444; }

/* ==========================================================================
   MEMAKSA TOMBOL BENTUK PIL (SINKRONISASI DENGAN TEMA UTAMA - MODERN)
   ========================================================================== */

.prodi-crud-wrapper #btn-submit-attitude,
.prodi-crud-wrapper #btn-refresh-attitude,
.prodi-crud-wrapper .btn-detail-attitude,
.prodi-crud-wrapper .btn-selesai-attitude,
.prodi-modal-content .modal-close-button {
    border-radius: 50px !important; 
    padding: 8px 25px !important;   /* <-- Bantalan diperkecil agar lebih ramping */
    font-size: 12px !important;     /* <-- Ukuran font diperkecil (standar modern) */
    font-weight: 600 !important;    /* <-- Semi-bold, tidak terlalu tebal/kaku */
    line-height: normal !important; /* <-- Mencegah tombol melar ke atas-bawah */
    height: auto !important;
    text-decoration: none !important;
    box-shadow: none !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* Penyesuaian khusus tombol "Tutup" di modal agar bergaya sekunder (putih-abu) */
.prodi-modal-content .modal-close-button {
    background-color: #ffffff !important;
    border: 1px solid #cbd5e1 !important;
    color: #475569 !important;
    transition: all 0.2s ease !important;
}

.prodi-modal-content .modal-close-button:hover {
    background-color: #fee2e2 !important;
    color: #b91c1c !important;
    border-color: #fca5a5 !important;
}

/* ==========================================================================
   GAYA FILTER ATTITUDE (LABEL KECIL & SELECT BENTUK PIL)
   ========================================================================== */

/* 1. Mengatur container filter agar rata tengah secara vertikal */
.prodi-filter-container {
    align-items: center !important; 
    padding: 15px 25px !important;
}

/* 2. Mensejajarkan label dan kotak input agar berjejer menyamping */
.prodi-filter-container .filter-group {
    display: flex;
    align-items: center;
    gap: 10px; /* Jarak antara label dan kotak input */
    margin: 0;
}

/* 3. Mengecilkan teks Label agar seimbang dengan tombol */
.prodi-filter-container .filter-group label {
    font-size: 12px !important;
    font-weight: 600 !important;
    color: #475569 !important;
    margin: 0 !important;
    white-space: nowrap; /* Mencegah teks terpotong ke bawah */
}

/* 4. Mengubah kotak Dropdown (Select) menjadi BENTUK PIL */
.prodi-filter-container .filter-group select.prodi-select {
    border-radius: 50px !important; /* <-- Kunci Bentuk Pil */
    padding: 12px 30px 6px 15px !important; /* Padding proporsional */
    font-size: 12px !important; /* <-- Teks disamakan dengan tombol (12px) */
    font-weight: 500 !important;
    color: #1e293b !important;
    border: 1px solid #cbd5e1 !important;
    background-color: #f8fafc !important;
    height: auto !important;
    min-width: 180px;
    
    /* Ikon Panah Dropdown Kustom yang rapi */
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%2364748b' class='bi bi-chevron-down' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 12px center !important;
    background-size: 12px 12px !important;
    
    transition: all 0.2s ease !important;
    cursor: pointer;
}

/* 5. Efek animasi saat dropdown di-hover atau di-klik */
.prodi-filter-container .filter-group select.prodi-select:hover {
    border-color: #94a3b8 !important;
    background-color: #f1f5f9 !important;
}
.prodi-filter-container .filter-group select.prodi-select:focus {
    border-color: #090999 !important;
    box-shadow: 0 0 0 2px rgba(9, 9, 153, 0.2) !important;
    outline: none !important;
    background-color: #ffffff !important;
}


/* ==========================================================================
   PENGATURAN LEBAR KOLOM & ALIGNMENT TABEL REKAP ATTITUDE
   ========================================================================== */

/* 1. Pastikan layout tabel fixed agar persentase kolom dipatuhi */
.attitude-table {
    table-layout: fixed !important;
    width: 100% !important;
    min-width: 1000px; /* Cegah tabel terlalu hancur di layar kecil/HP */
}

/* 2. Pengaturan Lebar Kolom (Total = 100%) */
.attitude-table th:nth-child(1) { width: 3% !important; }  /* No */
.attitude-table th:nth-child(2) { width: 10% !important; } /* Tgl Kejadian */
.attitude-table th:nth-child(3) { width: 22% !important; } /* Taruna */
.attitude-table th:nth-child(4) { width: 8% !important; }  /* Prodi */
.attitude-table th:nth-child(5) { width: 8% !important; }  /* Kelas */
.attitude-table th:nth-child(6) { width: 25% !important; } /* Pelapor */
.attitude-table th:nth-child(7) { width: 10% !important; } /* Status */
.attitude-table th:nth-child(8) { width: 15% !important; } /* Aksi */

/* 3. Pengaturan Perataan Teks (Alignment) untuk Header & Body */

/* Rata Tengah: No, Tgl, Prodi, Kelas, Status, Aksi */
.attitude-table th:nth-child(1), .attitude-table td:nth-child(1),
.attitude-table th:nth-child(2), .attitude-table td:nth-child(2),
.attitude-table th:nth-child(4), .attitude-table td:nth-child(4),
.attitude-table th:nth-child(5), .attitude-table td:nth-child(5),
.attitude-table th:nth-child(7), .attitude-table td:nth-child(7),
.attitude-table th:nth-child(8), .attitude-table td:nth-child(8) {
    text-align: center !important;
    vertical-align: middle !important;
}

/* Rata Kiri: Taruna, Pelapor (karena bisa mengandung teks panjang) */
.attitude-table th:nth-child(3), .attitude-table td:nth-child(3),
.attitude-table th:nth-child(6), .attitude-table td:nth-child(6) {
    text-align: left !important;
    vertical-align: middle !important;
    padding-left: 15px !important; /* Jarak agar teks tidak menempel garis */
}

/* 4. Pastikan teks panjang bisa turun ke bawah (Wrapping) */
.attitude-table td {
    white-space: normal !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    line-height: 1.4 !important;
}

/* 5. Styling khusus untuk label kecil (NIM/Notar) di bawah nama Taruna */
.attitude-table td:nth-child(3) small {
    display: block;
    color: #64748b;
    font-size: 11px;
    margin-top: 3px;
}


/* ==========================================================================
   MEMUSATKAN TOMBOL DI KOLOM AKSI
   ========================================================================== */
.attitude-table td:nth-child(8) > div {
    justify-content: center !important;
}


/* ==========================================================================
   GAYA FORM LAPORAN ATTITUDE (MODERN, STYLISH & PILL-SHAPED)
   ========================================================================== */

/* 1. Wadah Utama Form (Card Style Modern) */
.prodi-form {
    background: #ffffff;
    padding: 35px 40px;
    border-radius: 20px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.01);
    border: 1px solid #e2e8f0;
    margin-top: 25px;
}

/* 2. Layout Grid / Baris */
.form-group-row {
    display: flex;
    gap: 24px;
    margin-bottom: 24px;
}

.form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* 3. Tipografi Label yang Elegan */
.form-group label {
    font-size: 12px !important;
    font-weight: 700 !important;
    color: #0d1e4d !important; /* Warna biru tua khas sistem Anda */
    margin-bottom: 10px !important;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    display: block;
}

.form-group label .required {
    color: #ef4444;
    font-size: 14px;
}

/* 4. Kolom Isian Bergaya Pill (Kapsul) */
.form-group .prodi-input, 
.form-group .prodi-select {
    width: 100%;
    padding: 12px 24px !important;
    font-size: 14px !important;
    color: #1e293b !important;
    background-color: #f8fafc !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 50px !important; /* <-- Kunci Gaya Pill */
    transition: all 0.3s ease !important;
    font-family: inherit;
}

/* Khusus Textarea tidak bisa full Pill, kita beri sudut melengkung halus (Squircle) */
.form-group textarea.prodi-input {
    border-radius: 16px !important; 
    padding: 16px 24px !important;
    resize: vertical;
    min-height: 120px;
}

/* Efek Glow Biru saat kolom sedang diketik/di-klik */
.form-group .prodi-input:focus, 
.form-group .prodi-select:focus {
    background-color: #ffffff !important;
    border-color: #0d1e4d !important;
    box-shadow: 0 0 0 4px rgba(13, 30, 77, 0.1) !important;
    outline: none !important;
}

/* 5. OVERRIDE CHOICES.JS AGAR MENJADI PILL (Menimpa gaya kotak bawaan library) */
.choices {
    margin-bottom: 0 !important;
}
.choices__inner {
    padding: 9px 24px !important;
    background-color: #f8fafc !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 50px !important; /* <-- Mengubah Choices jadi Pill */
    font-size: 14px !important;
    min-height: 46px;
    display: flex;
    align-items: center;
    transition: all 0.3s ease !important;
}
.choices.is-focused .choices__inner {
    background-color: #ffffff !important;
    border-color: #0d1e4d !important;
    box-shadow: 0 0 0 4px rgba(13, 30, 77, 0.1) !important;
}
.choices__list--dropdown {
    border-radius: 16px !important; /* Dropdown membulat elegan */
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1) !important;
    z-index: 99 !important;
    margin-top: 5px !important;
}

/* 6. Responsif untuk Layar HP */
@media (max-width: 768px) {
    .form-group-row {
        flex-direction: column;
        gap: 16px;
        margin-bottom: 16px;
    }
    .prodi-form {
        padding: 25px 20px;
    }
}

/* ==========================================================================
   FIX: MENCEGAH TEKS DROPDOWN TERPOTONG & MENYAMAKAN TINGGI
   ========================================================================== */

.form-group select.prodi-select {
    min-height: 46px !important; /* Menyamakan tinggi dengan form nama dosen */
    line-height: 1.5 !important;
    
    /* Mematikan gaya bawaan browser yang menyebabkan teks terpotong */
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    
    /* Memasang ikon panah kustom yang lebih rapi */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%2364748b' class='bi bi-chevron-down' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 24px center !important; 
    background-size: 14px 14px !important;
    
    /* Memberi ruang di sebelah kanan agar teks tidak menabrak panah */
    padding-right: 50px !important; 
}
/* ==========================================================================
   GAYA FLOATING NOTIFIKASI (SUBMIT FORM)
   ========================================================================== */

/* Latar belakang blur gelap (Overlay) */
.prodi-floating-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    z-index: 99999; /* Pastikan selalu di paling depan */
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Kotak Notifikasi Putih Tengah */
.prodi-floating-box {
    background: #ffffff;
    padding: 30px 40px;
    border-radius: 24px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    text-align: center;
    max-width: 350px;
    width: 90%;
    transform: scale(0.9);
    animation: popUpNotif 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.prodi-floating-icon {
    font-size: 50px;
    margin-bottom: 10px;
    line-height: 1;
}

.prodi-floating-title {
    color: #0d1e4d !important; /* Biru tua khas sistem Anda */
    font-size: 20px !important;
    font-weight: 800 !important;
    margin: 0 0 10px 0 !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.prodi-floating-message {
    color: #475569 !important;
    font-size: 14px !important;
    margin-bottom: 25px !important;
    line-height: 1.5 !important;
}

/* Tombol OK gaya Pill */
.prodi-floating-btn {
    background: #0d1e4d !important;
    color: #ffffff !important;
    border: none !important;
    padding: 10px 20px !important;
    border-radius: 50px !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    cursor: pointer;
    transition: all 0.2s ease !important;
    display: inline-block;
}

.prodi-floating-btn:hover {
    background: #1e3a8a !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(13, 30, 77, 0.2);
}

/* Animasi Memantul (Bouncy) */
@keyframes popUpNotif { 
    to { transform: scale(1); } 
}

/* ==========================================================================
   GAYA TOMBOL ICON ONLY (TABEL REKAP)
   ========================================================================== */
.prodi-crud-wrapper .btn-icon-only {
    padding: 0 !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important; /* Memaksa bentuk bulat sempurna */
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.2s ease !important;
}

.prodi-crud-wrapper .btn-icon-only svg {
    margin: 0 !important;
    pointer-events: none; /* Mencegah svg mengganggu klik pada tombol */
}

/* Efek sedikit membesar saat disentuh mouse */
.prodi-crud-wrapper .btn-icon-only:hover {
    transform: scale(1.1);
}