/* --- Root Variables --- */
:root {
    --primary-color: #0d6efd;
    --danger-color: #dc3545;
    --success-color: #198754;
    --bg-light: #f4f7f6;
}

/* --- Base Style --- */
body {
    background-color: var(--bg-light);
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    color: #333;
}

.form-container {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    padding: 2rem;
    margin-top: 1.5rem;
}

/* --- Navigasi Tab --- */
.nav-pills .nav-link {
    color: #6c757d;
    font-weight: 600;
    font-size: 0.85rem;
    border: 1px solid #dee2e6;
    margin-right: 0.5rem;
    border-radius: 8px;
    padding: 0.6rem 1.2rem;
    background: #fff;
    transition: all 0.3s ease;
}

.nav-pills .nav-link.active {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.25);
}

.nav-pills .nav-link:hover:not(.active) {
    background-color: #f8f9fa;
    border-color: #adb5bd;
}

/* --- Section & Labels --- */
.section-title {
    border-left: 4px solid var(--primary-color);
    padding-left: 1rem;
    margin-bottom: 1.5rem;
    font-weight: 800;
    color: #2c3e50;
    font-size: 1rem;
    letter-spacing: 0.5px;
}

.form-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 0.3rem;
    color: #5a6268;
    font-weight: 700;
}

/* --- Form Inputs --- */
.form-control,
.form-select {
    border-radius: 6px;
    padding: 0.5rem 0.75rem;
    border: 1px solid #ced4da;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.1);
}

/* --- Validation & Shake Animation --- */
.is-invalid {
    border-color: var(--danger-color) !important;
    background-image: none !important;
    /* Hilangkan icon default bootstrap agar tidak tumpang tindih */
    animation: shake 0.25s cubic-bezier(.36, .07, .19, .97) both;
}

@keyframes shake {

    10%,
    90% {
        transform: translate3d(-1px, 0, 0);
    }

    20%,
    80% {
        transform: translate3d(2px, 0, 0);
    }

    30%,
    50%,
    70% {
        transform: translate3d(-4px, 0, 0);
    }

    40%,
    60% {
        transform: translate3d(4px, 0, 0);
    }
}

/* --- Table Styling --- */
.table {
    border-radius: 8px;
    overflow: hidden;
}

.table thead {
    background-color: #f8f9fa;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

#nilai_kontrak {
    font-size: 1.25rem;
    letter-spacing: 1px;
}

/* --- Toast Customization --- */
.toast {
    border-radius: 12px;
    font-size: 0.9rem;
    border: none;
}

.toast-container {
    z-index: 1100;
}

/* --- Footer Buttons --- */
.btn-lg {
    font-size: 1rem;
    font-weight: 700;
    padding: 0.8rem 2rem;
}